Data center network (DCN) architecture and communication

ABSTRACT

A DCN includes N first-level subnetworks, each first-level subnetwork includes N second-level subnetworks, each kth-level subnetwork includes N (k+1)th-level subnetworks, each (K−1)th-level subnetwork includes multiple switches, and the DCN is a K-level network; each switch in the DCN has K subnetwork identifiers, the K subnetwork identifiers are respectively used to indicate each level of subnetwork to which the switch belongs and a number in a (K−1)th-level subnetwork to which the switch belongs; and the switch is separately interconnected with each switch in K direct connection switch groups, each direct connection switch group includes N−1 switches, and an ith-level subnetwork identifier of the N−1 switches included in an ith direct connection switch group of the K direct connection switch groups is different from an ith-level subnetwork identifier of the switch, and is the same as other K−1 subnetwork identifiers of the switch.

CROSS-REFERENCE TO RELATED APPLICATIONS

This is a continuation of Int'l Patent App. No. PCT/CN2018/095578 filedon Jul. 13, 2018, which claims priority to Chinese Patent App. No.201710639666.5 filed on Jul. 31, 2017, which are incorporated byreference.

TECHNICAL FIELD

Embodiments of this disclosure relate to the communications field, andmore specifically, to a data center network DCN, a traffic transmissionmethod in the DCN, and a switch.

BACKGROUND

At present, with development of network communication, traffic andbandwidth of a data center grow exponentially, and large bandwidth and ahigh scalability capability have become a top demand of a data centercustomer. A data center network (DCN) based on a Clos architecture isgetting more widely deployed due to excellent scalability, a pluralityof equal-cost paths, and the like.

However, a Clos-based data center uses an aggregated structure from atop-of-rack (ToR) switch to a core switch. As a proportion of east-westtraffic increases, port density and a capacity of the core switch becomea bottleneck for a network-wide switching capacity.

Therefore, a new network architecture is needed to resolve the foregoingproblem.

SUMMARY

Embodiments of this disclosure provide a DCN, a traffic transmissionmethod in the DCN, and a switch, to avoid a bottleneck problem of anetwork-wide switching capacity caused by port density and a capacity ofa core switch in an aggregated data center.

According to a first aspect, a data center network DCN is provided,including: N first-level subnetworks, where each first-level subnetworkincludes N second-level subnetworks, each k^(th)-level subnetworkincludes N (k+1)^(th)-level subnetworks, each (K−1)^(th)-levelsubnetwork includes at least one switch, N, K, and k are integers, N≥2,K≥2, 1<k<K, and the DCN is a K-level network; each switch in the DCN hasK subnetwork identifiers, where the K subnetwork identifiers arerespectively used to indicate each level of subnetwork to which theswitch belongs and a number of the switch in a (K−1)^(th)-levelsubnetwork to which the switch belongs; and the switch is separatelyinterconnected with each switch in K direct connection switch groups,where each direct connection switch group includes N−1 switches, ani^(th)-level subnetwork identifier of the N−1 switches included in ani^(th) direct connection switch group of the K direct connection switchgroups is different from an i^(th)-level subnetwork identifier of theswitch, and is the same as other K−1 subnetwork identifiers of theswitch, and i=1, . . . , and K.

Therefore, the DCN in this embodiment of this disclosure is adistributed structure, the distributed structure may also be referred toas a K-level MESH structure, and a connection between a switch andanother switch may be referred to as a distributed connection or a MESHconnection. In the DCN, each switch is equal in status, and there is norole of a core switch in a conventional Clos structure, helping avoid abottleneck problem of a network-wide capacity caused by port density anda capacity of the core switch.

Alternatively, a distributed network architecture in this embodiment ofthis disclosure can distribute a network-wide switching capacity to eachswitch, reducing a capacity requirement for a single switch, andavoiding a bottleneck problem of a switching capacity caused by anaggregated structure.

In a possible implementation of the first aspect, the switch includes Kinterconnection port groups, each interconnection port group includesN−1 interconnection ports, the K interconnection port groups correspondto the K direct connection switch groups, and the N−1 interconnectionports in each interconnection port group are respectively configured toconnect N−1 switches in one corresponding direct connection switchgroup.

Each switch can implement a connection to the K direct connection switchgroups by using the K interconnection port groups, and there is only onedifferent subnetwork identifier between K subnetwork identifiers of eachswitch in the K direct connection switch groups and K subnetworkidentifiers of the switch. Therefore, it may be understood that if onlyone subnetwork identifier between two switches is different, the twoswitches are connected through an interconnection port of the Kinterconnection port groups, or in other words, there is a one-hopreachable path between the two switches. Each interconnection portincludes a pair of ports (including an input port and an output port),and correspondingly, the K interconnection port groups include K inputport groups and K output port groups.

An interconnection between each switch and the K direct connectionswitch groups can be implemented by using the K interconnection portgroups of each switch, and a direct interconnection or an indirectinterconnection between every two switches in the DCN can be furtherimplemented. That is, there is a one-hop or multiple-hop reachabletransmission path between every two switches in the DCN. Each switchcorresponds to one direct connection switch group in the DCN to whichthe switch belongs, and in each level of subnetwork. Therefore, whentraffic is forwarded from a source switch to a destination switch, atraffic forwarding path from the source switch to the destination switchmay be designed based on an interconnection structure between switchesin the DCN.

In a possible implementation of the first aspect, K is 3, thefirst-level subnetwork of the DCN is a plane, the second-levelsubnetwork is a group, an identifier of the first-level subnetwork is aplane identifier, an identifier of the second-level subnetwork is agroup identifier, and an identifier of a third-level subnetwork is anintra-group identifier; and a first direct connection switch group inthe K direct connection switch groups is a planar direct connectionswitch group and includes N−1 switches whose plane identifier isdifferent from a plane identifier of the switch and whose groupidentifier and intra-group identifier are the same as a group identifierand an intra-group identifier of the switch, a second direct connectionswitch group is an inter-group direct connection switch group andincludes N−1 switches whose group identifier is different from the groupidentifier of the switch and whose plane identifier and intra-groupidentifier are the same as the plane identifier and the intra-groupidentifier of the switch, and a third direct connection switch group isan intra-group direct connection switch group and includes N−1 switcheswhose intra-group identifier is different from the intra-groupidentifier of the switch and whose plane identifier and group identifierare the same as the plane identifier and the group identifier of theswitch.

In a possible implementation of the first aspect, the K interconnectionport groups include an inter-plane interconnection port group, aninter-group interconnection port group, and an intra-groupinterconnection port group, the inter-plane interconnection port groupincludes N−1 inter-plane interconnection ports, the inter-groupinterconnection port group includes N−1 inter-group interconnectionports, and the intra-group interconnection port group includes N−1intra-group interconnection port; and the N−1 inter-planeinterconnection ports are configured to connect the N−1 switches in theplanar direct connection switch group, the N−1 inter-groupinterconnection ports are configured to connect the N−1 switches in theinter-group direct connection switch group, and the N−1 intra-groupinterconnection ports are configured to connect the N−1 switches in theintra-group direct connection switch group.

In a possible implementation of the first aspect, the K interconnectionport groups of the switch are connected to the K direct connectionswitch groups through K cyclic arrayed waveguide gratings CAWGs, eachCAWG includes N input optical fibers and N output optical fibers, andthe N−1 interconnection ports in each interconnection port group of theswitch include N−1 input ports and N−1 output ports; and the N−1 outputports in each interconnection port group of the switch are connected toan input optical fiber of a CAWG, and the N−1 input ports in theinterconnection port group are connected to an output optical fiber ofthe CAWG.

For example, the switch may connect N−1 intra-group interconnectionports of the switch to a pair of optical fibers of the CAWG (includingan input optical fiber and an output optical fiber), and a first switchin the intra-group direct connection switch group may also connect N−1intra-group interconnection ports of the first switch to another pair ofoptical fibers of the CAWG. That is, both the switch and a switch in theintra-group direct connection switch group of the switch may beconnected to a pair of optical fibers of the CAWG, so that aninterconnection between the switch and the intra-group direct connectionswitch group can be implemented through the CAWG.

According to a second aspect, a traffic transmission method in a datacenter network DCN is provided, where the DCN includes: N first-levelsubnetworks, where each first-level subnetwork includes N second-levelsubnetworks, each kth-level subnetwork includes N (k+1)^(th)-levelsubnetworks, each (K−1)^(th)-level subnetwork includes at least oneswitch, N, K, and k are integers, N≥2, K≥2, 1<k<K, and the DCN is aK-level network; each switch in the DCN has K subnetwork identifiers,where the K subnetwork identifiers are respectively used to indicateeach level of subnetwork to which the switch belongs and a number of theswitch in a (K−1)^(th)-level subnetwork to which the switch belongs; andthe switch is separately interconnected with each switch in K directconnection switch groups, where each direct connection switch groupincludes N−1 switches, an i^(th)-level subnetwork identifier of the N−1switches included in an i^(th) direct connection switch group of the Kdirect connection switch groups is different from an i^(th)-levelsubnetwork identifier of the switch, and is the same as other K−1subnetwork identifiers of the switch, and i=1, . . . , and K; and themethod includes: receiving, by a source switch, target traffic sent by aserver; determining, by the source switch, a target transmission pathfrom the source switch to a destination switch based on a pre-storedtransmission path set, where the pre-stored transmission path setincludes a transmission path between any two switches in the DCN, andthe transmission path between every two switches includes a plurality oftransmission paths; and sending, by the source switch, the targettraffic to the destination switch over the target transmission path,where the source switch is any switch in the DCN, and the destinationswitch is any switch except the source switch in the DCN.

Therefore, in the traffic transmission method in this embodiment of thisdisclosure, the target transmission path from the source switch to thedestination switch is pre-determined. When traffic is forwarded, thetarget traffic may be forwarded only by needing to query the pre-storedtransmission path set, so that a traffic forwarding delay can beshortened.

In a possible implementation of the second aspect, the method furtherincludes: generating the target transmission path from the source switchto the destination switch; and adding the target transmission path tothe transmission path set.

In a possible implementation of the second aspect, the generating thetarget transmission path from the source switch to the destinationswitch includes: determining a first path set, where the first path setincludes a one-hop reachable transmission path between switches in theDCN; determining a first switch set and a second switch set, where thefirst switch set includes the source switch and all direct connectionswitches of the source switch, and the second switch set includes thedestination switch and all direct connection switches of the destinationswitch; determining a second path set from a switch in the first switchset to a switch in the second switch set based on the first path set;and determining the target transmission path from the source switch tothe destination switch based on the first path set and the second pathset, where the target transmission path includes a plurality oftransmission paths from the source switch to the destination switch.

In a possible implementation of the second aspect, the determining thetarget transmission path from the source switch to the destinationswitch based on the first path set and the second path set includes:determining a first transmission path group in the second path set,where the first transmission path group includes N transmission pathswith a minimum hop count from the source switch and a first directconnection switch group interconnected with the source switch to thedestination switch and a second direct connection switch groupinterconnected with the destination switch, the first direct connectionswitch group is any direct connection switch group interconnected withthe source switch, and the second direct connection switch group is anydirect connection switch group interconnected with the destinationswitch; determining, in the first path set, a second transmission pathgroup from the source switch to the first direct connection switchgroup, and a third transmission path group from the second directconnection switch group to the destination switch, where the secondtransmission path group includes N−1 transmission paths from the sourceswitch to the first direct connection switch group, and the thirdtransmission path group includes N−1 transmission paths from the seconddirect connection switch group to the destination switch; anddetermining the target transmission path from the source switch to thedestination switch based on the second transmission path group, thefirst transmission path group, and the third transmission path group.

The first direct connection switch group includes the source switch andN−1 switches directly connected to the source switch, that is, the firstswitch set includes N switches. The second direct connection switchgroup includes the destination switch and N−1 switches directlyconnected to the destination switch, that is, the second switch setincludes N switches. The N transmission paths included in the firsttransmission path group are respectively configured to connect the Nswitches in the first switch set to the N switches in the second switchset, or in other words, the switch in the first switch set may transmittraffic to a corresponding switch in the second switch set over acorresponding transmission path.

Optionally, the first direct connection switch group is N−1 directconnection switches of the source switch. For example, the first directconnection switch group may be an intra-group direct connection switchgroup, an inter-group direct connection switch group or a planar directconnection switch group of the source switch, and in the first hop, thesource switch may separately forward N−1 pieces of sub-traffic to theN−1 switches of the first direct connection switch group. The seconddirect connection switch group is N−1 direct connection switches of thedestination switch. For example, the second direct connection switchgroup may be an intra-group direct connection switch group, aninter-group direct connection switch group or a planar direct connectionswitch group of the destination switch, and in a last hop, the N−1switches in the second direct connection switch group forward the N−1pieces of sub-traffic to the destination switch.

In a possible implementation of the second aspect, the sending, by thesource switch, the target traffic to the destination switch over thetarget transmission path includes: performing, by the source switch,traffic balancing on the target traffic to obtain N pieces ofsub-traffic; separately sending, by the source switch, N−1 pieces ofsub-traffic in the N pieces of sub-traffic to N−1 direct connectionswitches in the first direct connection switch group over the N−1transmission paths in the second transmission path group; separatelysending, by the source switch and the first direct connection switchgroup, the N pieces of sub-traffic to the destination switch and N−1direct connection switches in the second direct connection switch groupover the N transmission paths in the first transmission path group;sending, by the N−1 switches in the second direct connection switchgroup, the N−1 pieces of sub-traffic to the destination switch over theN−1 transmission paths in the third transmission path group; andaggregating, by the destination switch, the received N pieces ofsub-traffic to obtain the target traffic.

In a possible implementation of the second aspect, K is 3, thefirst-level subnetwork of the DCN is a plane, the second-levelsubnetwork is a group, an identifier of the first-level subnetwork is aplane identifier, an identifier of the second-level subnetwork is agroup identifier, and an identifier of a third-level subnetwork is anintra-group identifier; and a first direct connection switch group inthe K direct connection switch groups is a planar direct connectionswitch group and includes N−1 switches whose plane identifier isdifferent from a plane identifier of the source switch and whose groupidentifier and intra-group identifier are the same as a group identifierand an intra-group identifier of the source switch, a second directconnection switch group is an inter-group direct connection switch groupand includes N−1 switches whose group identifier is different from thegroup identifier of the source switch and whose plane identifier andintra-group identifier are the same as the plane identifier and theintra-group identifier of the source switch, and a third directconnection switch group is an intra-group direct connection switch groupand includes N−1 switches whose intra-group identifier is different fromthe intra-group identifier of the source switch and whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the source switch.

In a possible implementation of the second aspect, if the planeidentifier of the source switch is different from a plane identifier ofthe destination switch, the first direct connection switch group is anintra-group direct connection switch group of the source switch, and thesecond direct connection switch group is an intra-group directconnection switch group of the destination switch; and the separatelysending, by the source switch and the first direct connection switchgroup, the N pieces of sub-traffic to the destination switch and N−1direct connection switches in the second direct connection switch groupover the first transmission path group includes: sending, by a firstswitch over a first transmission sub-path in the first transmission pathgroup, an obtained piece of sub-traffic to a second switch whose planeidentifier is the same as the plane identifier of the source switch,whose group identifier is the same as a group identifier of thedestination switch, and whose intra-group identifier is the same as anintra-group identifier of the first switch, where the first switch isthe source switch or any switch in the first direct connection switchgroup, and the first transmission sub-path is a transmission path fromthe first switch to the second switch; and sending, by the second switchover a second transmission sub-path in the first transmission pathgroup, the received piece of sub-traffic to a third switch whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the destination switch and whose intra-groupidentifier is the same as the intra-group identifier of the secondswitch, where the third switch is the destination switch or any switchin the second direct connection switch group, and the secondtransmission sub-path is a transmission path from the second switch tothe third switch.

In general, the foregoing traffic transmission method may include thefollowing steps:

First, intra-group traffic balancing is performed on the target traffic.The source switch distributes the N pieces of sub-traffic to N switchesin a group.

Next, inter-group traffic forwarding is performed. The N switches thatobtain the pieces of sub-traffic separately forward the obtained piecesof sub-traffic to a group of switches whose plane identifier is the sameas the plane identifier of the source switch and whose group identifieris the same as the group identifier of the destination switch.

Then, inter-plane traffic forwarding is performed. The N switches thatobtain the pieces of sub-traffic forward the obtained pieces ofsub-traffic to a group of switches whose plane identifier and groupidentifier are the same as the plane identifier and the group identifierof the destination switch.

Finally, intra-group traffic aggregation is performed. The N−1 switchesexcept the destination switch in the group to which the destinationswitch belongs forward the obtained pieces of sub-traffic to thedestination switch, and the destination switch aggregates the obtained Npieces of sub-traffic to obtain the target traffic.

In a possible implementation of the second aspect, if the planeidentifier of the source switch is different from a plane identifier ofthe destination switch, the first direct connection switch group is anintra-group direct connection switch group of the source switch, and thesecond direct connection switch group is an intra-group directconnection switch group of the destination switch; and the separatelysending, by the source switch and the first direct connection switchgroup, the N pieces of sub-traffic to the destination switch and thesecond direct connection switch group over the first transmission pathgroup includes: sending, by a first switch over a first transmissionsub-path in the first transmission path group, an obtained piece ofsub-traffic to a second switch whose plane identifier is the same as theplane identifier of the destination switch, whose group identifier isthe same as the group identifier of the source switch, and whoseintra-group identifier is the same as an intra-group identifier of thefirst switch, where the first switch is the source switch or any switchin the first direct connection switch group, and the first transmissionsub-path is a transmission path from the first switch to the secondswitch; and sending, by the second switch over a second transmissionsub-path in the first transmission path group, the received piece ofsub-traffic to a third switch whose plane identifier and groupidentifier are the same as the plane identifier and a group identifierof the destination switch and whose intra-group identifier is the sameas the intra-group identifier of the second switch, where the thirdswitch is the destination switch or any switch in the second directconnection switch group, and the second transmission sub-path is atransmission path from the second switch to the third switch.

In general, the foregoing traffic transmission method may include thefollowing steps:

First, intra-group balancing is performed on the target traffic. Thesource switch distributes the N pieces of sub-traffic to N switches in agroup.

Next, inter-plane traffic forwarding is performed. The N switches thatobtain the pieces of sub-traffic separately forward the N pieces ofsub-traffic to a group of switches whose plane identifier is the same asthe plane identifier of the destination switch and whose groupidentifier is the same as the group identifier of the source switch.

Then, inter-group traffic forwarding is performed. The N switches thatobtain the pieces of sub-traffic forward the obtained pieces ofsub-traffic to a group of switches whose plane identifier and groupidentifier are the same as the plane identifier and the group identifierof the destination switch.

Finally, intra-group traffic aggregation is performed. The N−1 switchesexcept the destination switch in the group to which the destinationswitch belongs forward the obtained pieces of sub-traffic to thedestination switch, and the destination switch aggregates the obtained Npieces of sub-traffic to obtain the target traffic.

In a possible implementation of the second aspect, the first switch setincludes K direct connection switch groups interconnected with thesource switch, and the second switch set includes K direct connectionswitch groups interconnected with the destination switch.

A first direct connection switch group in the K direct connection switchgroups is a planar direct connection switch group and includes N−1switches whose plane identifier is different from a plane identifier ofthe switch and whose group identifier and intra-group identifier are thesame as a group identifier and an intra-group identifier of the switch,a second direct connection switch group is an inter-group directconnection switch group and includes N−1 switches whose group identifieris different from the group identifier of the switch and whose planeidentifier and intra-group identifier are the same as the planeidentifier and the intra-group identifier of the switch, and a thirddirect connection switch group is an intra-group direct connectionswitch group and includes N−1 switches whose intra-group identifier isdifferent from the intra-group identifier of the switch and whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the switch.

In a possible implementation of the second aspect, the K interconnectionport groups include an inter-plane interconnection port group, aninter-group interconnection port group, and an intra-groupinterconnection port group, the inter-plane interconnection port groupincludes N−1 inter-plane interconnection ports, the inter-groupinterconnection port group includes N−1 inter-group interconnectionports, and the intra-group interconnection port group includes N−1intra-group interconnection port; and the N−1 inter-planeinterconnection ports are configured to connect the N−1 switches in theplanar direct connection switch group, the N−1 inter-groupinterconnection ports are configured to connect the N−1 switches in theinter-group direct connection switch group, and the N−1 intra-groupinterconnection ports are configured to connect the N−1 switches in theintra-group direct connection switch group.

According to a third aspect, a switch is provided, including: Kinterconnection port groups, configured to respectively connect K directconnection switch groups of the switch; an access port, configured toconnect a server; and a switching chip, configured to: obtain, throughthe access port, target traffic sent by the server, determine a targettransmission path from the switch to a destination switch based on apre-stored transmission path set, and send the target traffic to thedestination switch over the target transmission path, where thepre-stored transmission path set includes a transmission path betweenany two switches in a data center network DCN in which the switch islocated, the transmission path between every two switches includes aplurality of transmission paths, the DCN is a K-level network, theswitch has K subnetwork identifiers, the K subnetwork identifiers arerespectively used to indicate each level of subnetwork to which theswitch belongs and a number of the switch in a (K−1)^(th)-levelsubnetwork to which the switch belongs, an i^(th)-level subnetworkidentifier of N−1 switches included in an i^(th) direct connectionswitch group of the K direct connection switch groups is different froman i^(th)-level subnetwork identifier of the switch, and is the same asother K−1 subnetwork identifiers of the switch, N and K are integers,N≥2, K≥2, and i=1, . . . , and K.

In a possible implementation of the third aspect, the switch furtherincludes a processor, configured to: generate the target transmissionpath from the switch to the destination switch; and add the targettransmission path to the transmission path set.

In a possible implementation of the third aspect, when generating thetarget transmission path from the switch to the destination switch, theprocessor is configured to: determine a first path set, where the firstpath set includes a one-hop reachable transmission path between switchesin the DCN; determine a first switch set and a second switch set, wherethe first switch set includes the switch and all direct connectionswitches of the switch, and the second switch set includes thedestination switch and all direct connection switches of the destinationswitch; determine a second path set from a switch in the first switchset to a switch in the second switch set based on the first path set;and determine the target transmission path from the switch to thedestination switch based on the first path set and the second path set,where the target transmission path includes a plurality of transmissionpaths from the switch to the destination switch.

In a possible implementation of the third aspect, when determining thetarget transmission path from the switch to the destination switch basedon the first path set and the second path set, the processor isconfigured to: determine a first transmission path group in the secondpath set, where the first transmission path group includes Ntransmission paths with a minimum hop count from the switch and a firstdirect connection switch group interconnected with the switch to thedestination switch and a second direct connection switch groupinterconnected with the destination switch, the first direct connectionswitch group is any direct connection switch group interconnected withthe switch, and the second direct connection switch group is any directconnection switch group interconnected with the destination switch;determine, in the first path set, a second transmission path group fromthe switch to the first direct connection switch group, and a thirdtransmission path group from the second direct connection switch groupto the destination switch, where the second transmission path groupincludes N−1 transmission paths from the switch to the first directconnection switch group, and the third transmission path group includesN−1 transmission paths from the second direct connection switch group tothe destination switch; and determine the target transmission path fromthe switch to the destination switch based on the second transmissionpath group, the first transmission path group, and the thirdtransmission path group.

In a possible implementation of the third aspect, when sending thetarget traffic to the destination switch over the target transmissionpath, the switching chip is configured to: perform traffic balancing onthe target traffic to obtain N pieces of sub-traffic; separately sendN−1 pieces of sub-traffic in the N pieces of sub-traffic to N−1 directconnection switches in the first direct connection switch group over theN−1 transmission paths in the second transmission path group; and send,to another direct connection switch of the switch, sub-traffic forwardedby the switch, where the another direct connection switch does notbelong to the first direct connection switch group.

In a possible implementation of the third aspect, K is 3, thefirst-level subnetwork of the DCN is a plane, the second-levelsubnetwork is a group, an identifier of the first-level subnetwork is aplane identifier, an identifier of the second-level subnetwork is agroup identifier, and an identifier of a third-level subnetwork is anintra-group identifier; and a first direct connection switch group inthe K direct connection switch groups is a planar direct connectionswitch group and includes N−1 switches whose plane identifier isdifferent from a plane identifier of the switch and whose groupidentifier and intra-group identifier are the same as a group identifierand an intra-group identifier of the switch, a second direct connectionswitch group is an inter-group direct connection switch group andincludes N−1 switches whose group identifier is different from the groupidentifier of the switch and whose plane identifier and intra-groupidentifier are the same as the plane identifier and the intra-groupidentifier of the switch, and a third direct connection switch group isan intra-group direct connection switch group and includes N−1 switcheswhose intra-group identifier is different from the intra-groupidentifier of the switch and whose plane identifier and group identifierare the same as the plane identifier and the group identifier of theswitch.

Therefore, a DCN formed by a switch with the foregoing structure may beconsidered as a huge data exchange device, and each switch in a networkarchitecture may be considered as an interface board of the dataexchange device. Therefore, the data exchange device does not have anindependent interface board and control board, and all exchangefunctions and control functions are distributed in each interface board,namely, the switch, so that there is no role of a core switch in a Closstructure, helping avoid a bottleneck problem of a network-wide capacitycaused by port density and a capacity of the core switch.

According to a fourth aspect, a computer-readable medium is provided,where the computer-readable medium stores program code executed by anetwork device, and the program code includes an instruction used toperform the method in the second aspect or any possible implementationof the second aspect.

According to a fifth aspect, a computer program product is provided,where the computer program product includes computer program code. Whenexecuted by a computer, the computer program code enables the computerto perform the method in the second aspect or any possibleimplementation of the second aspect.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic structural diagram of a DCN according to anembodiment of this disclosure;

FIG. 2 is a schematic diagram of a working principle of a CAWG accordingto an embodiment of this disclosure;

FIG. 3 is a physical connection diagram of implementing a switchinterconnection through a CAWG;

FIG. 4 is a logical connection diagram of implementing a switchinterconnection through a CAWG;

FIG. 5 is a schematic diagram of a connection solution between a switchand a CAWG according to an embodiment of this disclosure;

FIG. 6 is a schematic diagram of another connection solution between aswitch and a CAWG according to an embodiment of this disclosure;

FIG. 7 is a schematic diagram of still another connection solutionbetween a switch and a CAWG according to an embodiment of thisdisclosure;

FIG. 8 is a schematic structural diagram of a switch according to anembodiment of this disclosure;

FIG. 9A and FIG. 9B are a schematic flowchart of a traffic transmissionmethod in a DCN according to an embodiment of this disclosure;

FIG. 10 is a schematic diagram of an example of a traffic transmissionmethod in a DCN according to an embodiment of this disclosure;

FIG. 11 is a schematic diagram of another example of a traffictransmission method in a DCN according to an embodiment of thisdisclosure;

FIG. 12 is a schematic flowchart of a traffic transmission method in aDCN according to another embodiment of this disclosure;

FIG. 13 is a schematic flowchart of an example of a traffic transmissionmethod in a DCN according to an embodiment of this disclosure; and

FIG. 14 is a schematic flowchart of another example of a traffictransmission method in a DCN according to an embodiment of thisdisclosure.

DESCRIPTION OF EMBODIMENTS

The following describes technical solutions of this disclosure withreference to accompanying drawings.

FIG. 1 is a schematic diagram of a DCN 100 according to an embodiment ofthis disclosure.

As shown in FIG. 1, the DCN 100 includes: N first-level subnetworks 110,where each first-level subnetwork 110 includes N second-levelsubnetworks 120, each k^(th)-level subnetwork includes N(k+1)^(th)-level subnetworks, each (K−1)^(th)-level subnetwork includesat least one switch 130, N, K, and k are integers, N≥2, K≥2, and 1<k<K.The DCN is a K-level network. A smallest network unit of the DCN is a(K−1)^(th)-level subnetwork, N (K−1)^(th)-level subnetworks form a(K−2)^(th)-level subnetwork, N (K−2)^(th)-level subnetworks form a(K−3)^(th)-level subnetwork, . . . , the N second-level subnetworks forma first-level subnetwork, and the N first-level subnetworks form theDCN.

Optionally, when K=3, for ease of differentiation and description, thefirst-level subnetwork is denoted as a plane, and the second-levelsubnetwork is denoted as a group. In an implementation of this case, theDCN includes N planes, each plane includes N groups, and each groupincludes N switches.

In the DCN, K subnetwork identifiers are used to identify each switch130, and the K subnetwork identifiers are respectively used to indicatethe first-level subnetwork, the second-level subnetwork, . . . , towhich the switch 130 belongs and a number of the switch 130 in the(K−1)^(th)-level subnetwork. That is, the K subnetwork identifiers arerespectively used to indicate each level of subnetwork to which theswitch belongs and the number of the switch in the (K−1)^(th)-levelsubnetwork to which the switch belongs.

In other words, the K subnetwork identifiers of each switch may beunderstood as coordinates of the switch in the DCN, and the first-levelsubnetwork, the second-level subnetwork, . . . , and the(K−1)^(th)-level subnetwork to which the switch belongs and the numberof the switch in the (K−1)^(th)-level subnetwork may be determined basedon the K subnetwork identifiers of the switch. For the K subnetworkidentifiers of each switch, the first K−1 subnetwork identifiers areused to identify subnetworks at different levels, and a K^(th)subnetwork identifier is used to indicate the number of the switch inthe (K−1)^(th)-level subnetwork to which the switch belongs. It shouldbe noted that the K^(th) subnetwork identifier is essentially a deviceidentifier that is used to indicate a switch and is not used to indicatea subnetwork. A subnetwork identifier is uniformly used in thisdisclosure for ease of description.

Optionally, when K=3, for ease of differentiation and description, the Ksubnetwork identifiers are denoted as a plane identifier, a groupidentifier, and an intra-group identifier respectively, to respectivelyidentify a plane and a group to which the switch belongs and anintra-group number. Therefore, the plane and the group to which theswitch belongs and the intra-group number may be determined based on theK subnetwork identifiers.

In the DCN, each switch is separately interconnected with each switch inK direct connection switch groups, where each direct connection switchgroup includes N−1 switches, the K direct connection switch groupsinterconnected with different switches are different, an i^(th)-levelsubnetwork identifier of the N−1 switches included in an i^(th) directconnection switch group of the K direct connection switch groups isdifferent from an i^(th)-level subnetwork identifier of the switch,other K−1 subnetwork identifiers of the N−1 switches included in thei^(th) direct connection switch group are the same as other K−1subnetwork identifiers of the switch, and i=1, . . . , and K. There isno other switch between each switch in a direct connection switch groupof a switch and the switch.

For example, as shown in FIG. 1, coordinates of a lower left switch aredenoted as (1, 1, 1), that is, a plane identifier is 1, a groupidentifier is 1, and an intra-group identifier is 1. The planeidentifier is incremented upward, and the group identifier isincremented rightward.

Then, a first direct connection switch group of the switch (1, 1, 1)includes N−1 switches whose plane identifier is different from the planeidentifier of the switch (1, 1, 1) and whose group identifier andintra-group identifier are the same as the group identifier and theintra-group identifier of the switch (1, 1, 1), that is, includes aswitch (W, 1, 1), where 2≤W≤N. The first direct connection switch groupincludes the N−1 switches with coordinates being from (2, 1, 1) to (N,1, 1).

A second direct connection switch group of the switch (1, 1, 1) includesN−1 switches whose group identifier is different from the groupidentifier of the switch (1, 1, 1) and whose plane identifier andintra-group identifier are the same as the plane identifier and theintra-group identifier of the switch (1, 1, 1), that is, includes aswitch (1, Q, 1), where 2≤Q≤N. The second direct connection switch groupincludes the N−1 switches with coordinates being from (1, 2, 1) to (1,N, 1).

A third direct connection switch group of the switch (1, 1, 1) includesN−1 switches whose intra-group identifier is different from theintra-group identifier of the switch (1, 1, 1) and whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the switch (1, 1, 1), that is, includes a switch(1, 1, P), where 2≤P≤N. The third direct connection switch groupincludes the N−1 switches with coordinates being from (1, 1, 2) to (1,1, N).

In the DCN, each switch is interconnected with the K direct connectionswitch groups, and there is only one different subnetwork identifierbetween K subnetwork identifiers of a switch in each direct connectionswitch group and K subnetwork identifiers of the switch. There is onlyone different first-level subnetwork identifier between K subnetworkidentifiers of a switch in the first direct connection switch group andthe K subnetwork identifiers of the switch. There is only one differentsecond-level subnetwork identifier between K subnetwork identifiers of aswitch in the second direct connection switch group and the K subnetworkidentifiers of the switch. There is only one different K^(th)-levelsubnetwork identifier between K subnetwork identifiers of a switch in aK^(th) direct connection switch group and the K subnetwork identifiersof the switch.

Optionally, when K=3, the first direct connection switch group includesN−1 switches whose plane identifier is different from the planeidentifier of the switch and whose group identifier and intra-groupidentifier are the same as the group identifier and the intra-groupidentifier of the switch, and is referred to as a planar directconnection switch group; the second direct connection switch groupincludes N−1 switches whose group identifier is different from the groupidentifier of the switch and whose plane identifier and intra-groupidentifier are the same as the plane identifier and the intra-groupidentifier of the switch, and is referred to as an inter-group directconnection switch group; and the third direct connection switch groupincludes N−1 switches whose intra-group identifier is different from theintra-group identifier of the switch and whose plane identifier andgroup identifier are the same as the plane identifier and the groupidentifier of the switch, and is referred to as an intra-group directconnection switch group. Each switch in the planar direct connectionswitch group is referred to as a planar direct connection switch of theswitch, each switch in the inter-group direct connection switch group isreferred to as an inter-group direct connection switch of the switch,and each switch in the intra-group direct connection switch group isreferred to as an intra-group direct connection switch of the switch.

Therefore, the DCN in this embodiment of this disclosure is adistributed structure, the distributed structure may also be referred toas a K-level MESH structure, and a connection between a switch andanother switch may be referred to as a distributed connection or a MESHconnection. In the DCN, each switch is equal in status, and there is norole of a core switch in a Clos structure, helping avoid a bottleneckproblem of a network-wide capacity caused by port density and a capacityof the core switch.

N^(K) switches are included in the K-level MESH structure. If eachswitch is connected to N servers, a network-wide switching capacity isN^(K+1)×port capacity. For example, when K=2, the DCN is a second-levelMESH structure, and the DCN includes N² switches. Each switch isconnected to N servers, and then the network-wide switching capacity isN³×port capacity. Alternatively, if K=3, the DCN is a three-level MESHstructure, and the DCN includes N³ switches. Each switch is connected toN servers, and then the network-wide switching capacity is N⁴×portcapacity.

K=3 and N=48 are used as an example, a quantity of switches included inthe DCN is 110,592, and a quantity of connected servers is 5,308,416. Ifa port connection is implemented through 10 Gigabit Ethernet (GbE), thenetwork-wide switching capacity is approximately 53 petabits per second(Pbps). If a quantity of ports of each switch is 4N, that is, a quantityof connected servers is 4N, and it can be equivalent to implementing 19210GE ports, and a switching capacity of each switch is 1.92 terabits persecond (Tbps). If a port rate of a server is 25GE, the network-wideswitching capacity can reach 133 Pbps. In this case, the switchingcapacity of each switch only needs to be 4.8 Tb. Therefore, adistributed network architecture in this embodiment of this disclosurecan distribute the network-wide switching capacity to each switch,reducing a capacity requirement for a single switch, and avoiding abottleneck problem of the switching capacity caused by an aggregatedstructure.

In this embodiment of this disclosure, each switch in the DCN includes Kinterconnection port groups, each interconnection port group includesN−1 interconnection ports, the K interconnection port groups correspondto the K direct connection switch groups, and the N−1 interconnectionports in each interconnection port group are respectively configured toconnect N−1 switches in one corresponding direct connection switchgroup.

Each switch can implement a connection to the K direct connection switchgroups by using the K interconnection port groups, and there is only onedifferent subnetwork identifier between the K subnetwork identifiers ofthe switch in the K direct connection switch groups and the K subnetworkidentifiers of the switch. Therefore, it may be understood that if onlyone subnetwork identifier between two switches is different, the twoswitches are connected through an interconnection port of the Kinterconnection port groups, or in other words, there is a one-hopreachable path between the two switches. Each interconnection portincludes a pair of ports (including an input port and an output port),and correspondingly, the K interconnection port groups include K inputport groups and K output port groups.

Optionally, when K=3, the K interconnection port groups are threeinterconnection port groups. For ease of differentiation anddescription, the three interconnection port groups are respectivelydenoted as an inter-plane interconnection port group, an inter-groupinterconnection port group, and an intra-group interconnection portgroup. The inter-plane interconnection port group includes N−1inter-plane interconnection ports, the inter-group interconnection portgroup includes N−1 inter-group interconnection ports, and theintra-group interconnection port group includes N−1 intra-groupinterconnection ports.

The N−1 inter-plane interconnection ports are configured to connect thefirst direct connection switch group, namely, the N−1 switches in theplanar direct connection switch group, the N−1 inter-groupinterconnection ports are configured to connect the second directconnection switch group, namely, the N−1 switches in the inter-groupdirect connection switch group, and the N−1 intra-group interconnectionports are configured to connect the third direct connection switchgroup, namely, the N−1 switches in the intra-group direct connectionswitch group.

The switch (1, 1, 1) in FIG. 1 is used as an example. N−1 inter-planeinterconnection ports of the switch (1, 1, 1) may be configured toconnect N−1 switches with coordinates being from (2, 1, 1) to (N, 1, 1),N−1 inter-group interconnection ports of the switch (1, 1, 1) may beconfigured to connect N−1 switches with coordinates being from (1, 2, 1)to (1, N, 1), and N−1 intra-group interconnection ports of the switch(1, 1, 1) are configured to connect N−1 switches with coordinates beingfrom (1, 1, 2) to (1, 1, N).

An interconnection between each switch and the K direct connectionswitch groups can be implemented by using the K interconnection portgroups of each switch, and a direct interconnection or an indirectinterconnection between every two switches in the DCN can be furtherimplemented. That is, there is a one-hop or multiple-hop reachabletransmission path between every two switches. Each switch corresponds toone direct connection switch group in the DCN to which the switchbelongs, and in each level of subnetwork. Therefore, when traffic isforwarded from a source switch to a destination switch, a trafficforwarding path from the source switch to the destination switch may bedesigned based on an interconnection structure between switches in theDCN.

For example, K subnetwork identifiers of the source switch are (S₁, S₂,. . . , S_(K)), and K subnetwork identifiers of the destination switchare (D₁, D₂, . . . , D_(K)). S₁, S₂, . . . , and S_(K) respectivelyrepresent a first-level subnetwork, a second-level subnetwork, . . . ,and a (K−1)^(th)-level subnetwork to which the source switch belongs,and a number in the (K−1)^(th)-level subnetwork, and D₁, D₂, . . . , andD_(K) respectively represent a first-level subnetwork, a second-levelsubnetwork, . . . , and a (K−1)^(th)-level subnetwork to which thedestination switch belongs, and a number in the (K−1)^(th)-levelsubnetwork.

Case 1:

There is only one different subnetwork identifier between the Ksubnetwork identifiers of the source switch and the K subnetworkidentifiers of the destination switch. That is, the destination switchis one of K direct connection switch groups of the source switch. Inother words, there is a one-hop reachable transmission path between thesource switch and the destination switch. Therefore, the source switchmay forward target traffic to the destination switch over the one-hopreachable transmission path.

Case 2:

There are at least two different subnetwork identifiers between the Ksubnetwork identifiers of the source switch and the K subnetworkidentifiers of the destination switch. In this case, one hop between thesource switch and the destination switch is unreachable. Therefore, ashortest transmission path from the source switch to the destinationswitch, namely, a transmission path with a minimum hop count, needs tobe determined.

A larger quantity of different subnetwork identifiers between the Ksubnetwork identifiers of the source switch and the K subnetworkidentifiers of the destination switch indicates a larger hop count fromthe source switch to the destination switch. When the K subnetworkidentifiers of the source switch are entirely different from the Ksubnetwork identifiers of the destination switch, that is, S₁≠D₁, S₂≠D₂,. . . , and S_(K)≠D_(K), there is a maximum hop count of trafficforwarding from the source switch to the destination switch, and thereare at least K hops.

The following describes a route design method from the source switch tothe destination switch by using a K-hop scenario as an example.

Step 1. A source switch (S₁, S₂, . . . , S_(K)) may forward targettraffic to a first switch whose K−1 subnetwork identifiers are the sameas K−1 subnetwork identifiers of the source switch (S₁, S₂, . . . ,S_(K)) and whose one subnetwork identifier is the same as one subnetworkidentifier of a destination switch, that is, one of the K subnetworkidentifiers (S₁, S₂, . . . , S_(K)) is replaced with one subnetworkidentifier of the destination switch, for example, (S₁, S₂, . . . ,D_(K)), and the source switch (S₁, S₂, . . . , S_(K)) forwards thetarget traffic to the switch (S₁, S₂, . . . , D_(K)). There are K−1identical subnetwork identifiers and one different subnetwork identifierbetween the first switch and the source switch. Therefore, the firstswitch is a switch that has a one-hop reachable path to the sourceswitch, and the source switch may forward the target traffic to thefirst switch over the one-hop reachable path.

For example, when K=3, three subnetwork identifiers of the source switchare (1, 1, 1), and three subnetwork identifiers of the destinationswitch are (3, 2, 2). When the target traffic is forwarded from thesource switch (1, 1, 1) to the destination switch (3, 2, 2), the targettraffic may be first forwarded from the source switch (1, 1, 1) to aswitch (1, 1, 2), two of three subnetwork identifiers of the switch (1,1, 2) are the same as two subnetwork identifiers of the source switch,and the other subnetwork identifier is the same as a subnetworkidentifier of the destination switch. Therefore, the source switch (1,1, 1) is interconnected with the switch (1, 1, 2) through an intra-groupinterconnection port, and the source switch (1, 1, 1) may forward thetarget traffic to the switch (1, 1, 2) through the intra-groupinterconnection port.

Step 2. The first switch may replace one of K subnetwork identifiers ofthe first switch with one subnetwork identifier of the destinationswitch in a processing manner similar to that of the source switch. Inthis case, the replaced subnetwork identifier is a subnetwork identifierthat was not replaced in step 1, or in other words, the replacedsubnetwork identifier herein is a subnetwork identifier that isdifferent from K subnetwork identifiers of the destination switch, forexample, (S₁, D₂, . . . , D_(K)), and the target traffic is forwarded tothe switch (S₁, D₂, . . . , D_(K)). In this manner, the target trafficis forwarded until the target traffic is forwarded to the destinationswitch, and traffic forwarding ends. Because one of the K subnetworkidentifiers is replaced during each forwarding and the target traffic isforwarded to the switch, K hops are used to forward the target trafficto the destination switch.

Following the foregoing example, after receiving the target traffic sentby the source switch, the switch (1, 1, 2) may forward the targettraffic to a switch (1, 2, 2), and the switch (1, 2, 2) isinterconnected with the switch (1, 1, 2) through an inter-groupinterconnection port. Therefore, the switch (1, 1, 2) may forward thetarget traffic to the switch (1, 2, 2) through the inter-groupinterconnection port. Then, the switch (1, 2, 2) forwards the receivedtarget traffic to the switch (3, 2, 2), and the switch (3, 2, 2) isinterconnected with the switch (1, 2, 2) through an inter-planeinterconnection port. Therefore, the switch (1, 2, 2) may forward thetarget traffic to the destination switch (3, 2, 2) through theinter-plane interconnection port.

The foregoing description is an example but is not a limitation, aforwarding path from the source switch (1, 1, 1) to the destinationswitch (3, 2, 2) may also be (1, 1, 1)→(3, 1, 1)→(3, 2, 1)→(3, 2, 2),(1, 1, 1)→(3, 1, 1)→(3, 1, 2)→(3, 2, 2), (1, 1, 1)→(1, 2, 1)→(1, 2,2)→(3, 2, 2), or the like. Provided that one of the K subnetworkidentifiers is replaced with a subnetwork identifier of the destinationswitch during each forwarding and the target traffic is forwarded to theswitch until all the K subnetwork identifiers of the switch are replacedwith the K subnetwork identifiers of the destination switch, the trafficforwarding ends.

In general, a hop count from the source switch to the destination switchmay be determined based on the K subnetwork identifiers of the sourceswitch and the destination switch. For example, if there is onedifferent subnetwork identifier between the source switch and thedestination switch, only one hop may be used to forward the targettraffic from the source switch to the destination switch. Alternatively,if there are M different subnetwork identifiers between the sourceswitch and the destination switch, at least M hops are used to forwardthe target traffic from the source switch to the destination switch. Aforwarding process may be as follows: The M different subnetworkidentifiers are replaced with subnetwork identifiers of the destinationswitch in sequence, and after each replacement, the target traffic isforwarded to a switch corresponding to replaced K subnetworkidentifiers, and this is denoted as one hop, until all the M differentsubnetwork identifiers are replaced with the subnetwork identifiers ofthe destination switch. At this point, the target traffic is forwardedto the destination switch, and the traffic forwarding ends.

Optionally, in this embodiment of this disclosure, the K interconnectionport groups of the switch are connected to the K direct connectionswitch groups through K cyclic arrayed waveguide gratings (CAWGs).

Each CAWG includes N input optical fibers and N output optical fibers,the N−1 interconnection ports in each interconnection port group of theswitch include N−1 input ports and N−1 output ports, the N−1 outputports in each interconnection port group of the switch are connected toan input optical fiber of a CAWG, and the N−1 input ports in theinterconnection port group are connected to an output optical fiber ofthe CAWG.

An example in which an interconnection between a switch and anintra-group direct connection switch group is implemented through a CAWGis used. The switch may connect N−1 intra-group interconnection ports ofthe switch to a pair of optical fibers of the CAWG (including an inputoptical fiber and an output optical fiber), and the first switch in theintra-group direct connection switch group may also connect N−1intra-group interconnection ports of the first switch to another pair ofoptical fibers of the CAWG, that is, both the switch and a switch in theintra-group direct connection switch group of the switch may beconnected to a pair of optical fibers of the CAWG, so that theinterconnection between the switch and the intra-group direct connectionswitch group can be implemented through the CAWG. The followingdescribes in detail an implementation of an interconnection between aswitch and a switch in each direct connection switch group withreference to FIG. 2 to FIG. 7.

It should be understood that, the example in which the interconnectionbetween the switches is implemented through the CAWG is merely used fordescription in this embodiment of this disclosure, but should notconstitute any limitation on this embodiment of this disclosure. In thisembodiment of this disclosure, another optical connection manner such asa silicon photonic connection manner may also be used to replace theCAWG to implement the interconnection between the switch and the switchin each direct connection switch group.

Before that the interconnection between the switch and the switch ineach direct connection switch group is implemented through the CAWG isdescribed in detail, first, a structure of the CAWG is described withreference to FIG. 2.

As shown in FIG. 2, one N×N CAWG has N input ports (a₁, a₂, . . . ,a_(N)) and N output ports (b₁, b₂, . . . , b_(N)), each input port isexternally connected to one input optical fiber, each output port isexternally connected to one output optical fiber, and each input opticalfiber has input optical signals with N wavelengths. For example, aninput optical fiber externally connected to an input port a₁ has inputoptical signals with N wavelengths that are respectively λ₁ ¹, λ₂ ¹, . .. , λ_(N) ¹. A superscript of λ indicates an input port numbercorresponding to an optical signal, and a subscript of λ indicates anumber of a wavelength in the input port.

Optical signals with different wavelengths on each input optical fibercan be allocated to different output optical fibers based on awavelength allocation characteristic of the CAWG, that is, outputoptical signals with N wavelengths are output from each output opticalfiber. An output optical fiber externally connected to an output port b₁has optical signals with N wavelengths that are respectively λ₁ ¹, λ₁ ²,. . . , λ₁ ^(N). Herein, a subscript of λ indicates an output portnumber corresponding to an optical signal, and a superscript of λindicates a number of a wavelength in the output port. Therefore, theCAWG can implement non-blocking exchange between optical signals of theN input optical fibers and optical signals of the N output opticalfibers.

Based on the foregoing characteristic of the CAWG, if each input opticalfiber of the CAWG is connected to a plurality of output ports of aswitch, and each output optical fiber of the CAWG is connected to aplurality of input ports of a switch. In this way, a MESH connectionbetween the switches connected through the input optical fiber and theoutput optical fiber of the CAWG may be implemented.

FIG. 3 is a schematic diagram of a physical connection of implementingan interconnection between eight switches through an 8×8 CAWG.

In FIG. 3, S1 to S8 indicate the eight switches interconnected throughthe 8×8 CAWG, and a connection line between a switch and the CAWGindicates a pair of optical fibers (including an input optical fiber andan output optical fiber), or may be a bidirectional optical fiber. Theinput optical fiber of the CAWG is connected to an output port of theswitch, and the output optical fiber is connected to an input port ofthe switch.

Therefore, eight input optical fibers and eight output optical fibers ofthe 8×8 CAWG are respectively connected to output ports and input portsof the eight switches, and a MESH connection of the input ports and theoutput ports of the eight switches can be implemented.

The eight switches are physically a star structure shown in FIG. 3, andare logically a MESH structure shown in FIG. 4. Therefore, a fullinterconnection between the switches is implemented through the CAWG, tosimplify a network structure.

In an existing solution, each pair of ports of the switch occupies apair of optical fibers, but N pairs of ports of the switch may bemultiplexed to a pair of optical fibers through the CAWG and beconnected to a pair of optical fibers of the CAWG. Therefore, using thenetwork architecture in this embodiment of this disclosure can reduce aquantity of optical fibers in the DCN to 1/N of a conventional solution,resolving a bottleneck of fiber deployment in the DCN and helping reduceoptical fiber costs in comparison with relatively high costs of amultimode optical fiber.

In addition, a CAWG solution is used, when a port of the switch isexpanded, it may be required to only connect a tail fiber to amultiplexer/demultiplexer. Therefore, there is no need to lay a pipelinefiber across an equipment room, facilitating network maintenance andcapacity expansion. The following describes several connection solutionsfor implementing a connection between the switch and the CAWG withreference to FIG. 5 to FIG. 7.

It should be noted that the following several connection solutions aremerely possible implementations used to implement the DCN in thisembodiment of this disclosure, and should not constitute any limitationon this disclosure, and this embodiment of this disclosure should not belimited thereto.

FIG. 5 is a schematic diagram of a connection solution between a switchand a CAWG according to an embodiment of this disclosure.

In a connection solution 1 shown in FIG. 5, an input/output port of aswitch S1 is an independent colored optical interface. Each input/outputport may input/output an optical signal with one wavelength.

At a transmit end (TX) of the switch S1, optical signals with eightwavelengths output from eight output ports are multiplexed to an opticalfiber by using a multiplexer and then are connected to an input opticalfiber of the CAWG.

At a receive end (RX) of the switch S1, an output optical fiber of theCAWG is connected to a demultiplexer, and the optical signals with eightwavelengths separated by the demultiplexer are separately input to eightinput ports of the switch.

Similarly, another switch may use the connection solution 1. An outputport of the switch is connected to an input optical fiber of the CAWG byusing the multiplexer, and an output optical fiber of the CAWG isconnected to an input port of the switch by using the demultiplexer. Inthis way, each switch is connected to a pair of input/output opticalfibers of the CAWG in the foregoing connection manner, so that a fullinterconnection between eight switches can be implemented through an 8×8CAWG, that is, a logical MESH connection is implemented through aphysical star connection.

FIG. 6 is a schematic diagram of another connection solution between aswitch and a CAWG according to an embodiment of this disclosure.

In a connection solution 2 shown in FIG. 6, an input/output port of theswitch is an electrical interface or a white optical port, then, anoptical-to-electrical converter needs to be externally connected to theinput/output port of the switch, and converts, into an optical signal,an electrical signal output from the output port, or converts, into anelectrical signal, an optical signal input to the input port of theswitch. Therefore, an optical-to-electrical conversion step is added tothe connection solution 2 relative to the connection solution 1.

At a TX of a switch S1, eight output ports on the switch S1 areconverted into eight colored optical interfaces by using anoptical-to-electrical converter, and optical signals output from theeight colored optical interfaces are multiplexed to an optical fiber byusing a multiplexer and then are connected to an input optical fiber ofthe CAWG.

At an RX of the switch S1, an output optical fiber of the CAWG separatesoptical signals with eight wavelengths by using a demultiplexer, andthen the optical signals with eight wavelengths are separately connectedto eight input ports after optical-to-electrical conversion is performedby using the optical-to-electrical converter.

Similarly, another switch may use the connection solution 2. Anoutput/input port of the switch is connected to a pair of input/outputoptical fibers of the CAWG, so that a full interconnection between eightswitches can be implemented through an 8×8 CAWG, that is, a logical MESHconnection is implemented through a physical star connection.

FIG. 7 is a schematic diagram of still another connection solutionbetween a switch and a CAWG according to an embodiment of thisdisclosure.

In a connection solution 3 shown in FIG. 7, a plurality of input/outputports of the switch are integrated into one colored optical integrationinterface by using a colored optical integration module.

Then, at a TX of a switch S1, optical signals with eight wavelengths maybe multiplexed to an optical fiber by using the colored opticalintegration interface, so that an output port of the colored opticalintegration interface of the switch may be directly connected to aninput optical fiber of the CAWG. At an RX of the switch S1, an outputoptical fiber of the CAWG is connected to an input port of the coloredoptical integration interface.

In general, each switch in a DCN may be interconnected with N−1 switchesby using N−1 colored optical interfaces, and the N−1 colored opticalinterfaces may be independent colored optical interfaces (as shown inFIG. 5), or a colored optical integration interface (as shown in FIG.7), or an electrical interface/a white optical port and anoptical-to-electrical converter (as shown in FIG. 6). An input port ofeach colored optical interface is connected to the input optical fiberof the CAWG, and an output port is connected to the output optical fiberof the CAWG.

Therefore, a conventional three-layer networking structure may besimplified to one-layer physical networking in the DCN implementedthrough the CAWG. An interconnection between the switch and a group ofswitches in each level of subnetwork can be implemented only by needingthe CAWG. Because a layer of network transfer is reduced, a deviceswitching capacity and a port quantity that are required for an entirenetwork are reduced by ½, and this is equivalent to saving half ofdevice and port costs.

Optionally, each switch in the DCN includes K interconnection portgroups, a processor, a switching chip, and at least one access port.

FIG. 8 specifically shows a switch 800 provided in an embodiment of thisdisclosure by using K=3 as an example. As shown in FIG. 8, the switch800 includes K interconnection port groups 810 (which specificallyincludes three interconnection port groups in FIG. 8, namely, anintra-group interconnection port group 810 a, an inter-groupinterconnection port group 810 b, and an inter-plane interconnectionport group 810 c), a processor 820, a switching chip 830, and an accessport 840.

The K interconnection port groups 810 are configured to connect K directconnection switch groups of the switch.

Specifically, each interconnection port group includes N−1interconnection ports, configured to respectively connect N−1 switchesin a direct connection switch group corresponding to the interconnectionport group.

The access port 840 is configured to connect a server.

The switching chip 830 is configured to: obtain, through the access port840, target traffic sent by the server, determine a target transmissionpath from the switch to a destination switch based on a pre-storedtransmission path set, and send the target traffic to the destinationswitch over the target transmission path. The destination switch is anyswitch except the switch in a DCN in which the switch is located. Thepre-stored transmission path set includes a transmission path betweenany two switches in the data center network DCN in which the switch islocated, the transmission path between every two switches includes aplurality of transmission paths, the DCN is a K-level network, theswitch has K subnetwork identifiers, the K subnetwork identifiers arerespectively used to indicate each level of subnetwork to which theswitch belongs and a number of the switch in a (K−1)^(th)-levelsubnetwork to which the switch belongs, an i^(th)-level subnetworkidentifier of N−1 switches included in an i^(th) direct connectionswitch group of the K direct connection switch groups is different froman i^(th)-level subnetwork identifier of the switch, and is the same asother K−1 subnetwork identifiers of the switch, N and K are integers,N≥2, K≥2, and i=1, . . . , and K.

The processor 820 is configured to: generate the target transmissionpath from the switch to the destination switch; and add the targettransmission path to the transmission path set.

When generating the target transmission path from the source switch tothe destination switch, the processor 820 is configured to: determine afirst path set, where the first path set includes a one-hop reachabletransmission path between switches in the DCN; determine a first switchset and a second switch set, where the first switch set includes thesource switch and all direct connection switches of the source switch,and the second switch set includes the destination switch and all directconnection switches of the destination switch; determine a second pathset from a switch in the first switch set to a switch in the secondswitch set based on the first path set; and determine the targettransmission path from the source switch to the destination switch basedon the first path set and the second path set, where the targettransmission path includes a plurality of transmission paths from thesource switch to the destination switch.

When determining the target transmission path from the source switch tothe destination switch based on the first path set and the second pathset, the processor 820 is configured to: determine a first transmissionpath group in the second path set, where the first transmission pathgroup includes N transmission paths with a minimum hop count from thesource switch and a first direct connection switch group interconnectedwith the source switch to the destination switch and a second directconnection switch group interconnected with the destination switch, thefirst direct connection switch group is any direct connection switchgroup interconnected with the source switch, and the second directconnection switch group is any direct connection switch groupinterconnected with the destination switch; determine, in the first pathset, a second transmission path group from the source switch to thefirst direct connection switch group, and a third transmission pathgroup from the second direct connection switch group to the destinationswitch, where the second transmission path group includes N−1transmission paths from the source switch to the first direct connectionswitch group, and the third transmission path group includes N−1transmission paths from the second direct connection switch group to thedestination switch; and determine the target transmission path from thesource switch to the destination switch based on the second transmissionpath group, the first transmission path group, and the thirdtransmission path group.

When sending the target traffic to the destination switch over thetarget transmission path, the switching chip 830 is configured to:perform traffic balancing on the target traffic to obtain N pieces ofsub-traffic; separately send N−1 pieces of sub-traffic in the N piecesof sub-traffic to N−1 direct connection switches in the first directconnection switch group over the N−1 transmission paths in the secondtransmission path group; and send, to another direct connection switchof the switch, sub-traffic forwarded by the switch, where the anotherdirect connection switch does not belong to the first direct connectionswitch group.

Optionally, in this embodiment of this disclosure, when K is 3, afirst-level subnetwork of the DCN is a plane, a second-level subnetworkis a group, an identifier of the first-level subnetwork is a planeidentifier, an identifier of the second-level subnetwork is a groupidentifier, and an identifier of a third-level subnetwork is anintra-group identifier; and a first direct connection switch group inthe K direct connection switch groups is a planar direct connectionswitch group and includes N−1 switches whose plane identifier isdifferent from a plane identifier of the switch and whose groupidentifier and intra-group identifier are the same as a group identifierand an intra-group identifier of the switch, a second direct connectionswitch group is an inter-group direct connection switch group andincludes N−1 switches whose group identifier is different from the groupidentifier of the switch and whose plane identifier and intra-groupidentifier are the same as the plane identifier and the intra-groupidentifier of the switch, and a third direct connection switch group isan intra-group direct connection switch group and includes N−1 switcheswhose intra-group identifier is different from the intra-groupidentifier of the switch and whose plane identifier and group identifierare the same as the plane identifier and the group identifier of theswitch.

In an optional implementation, the switch may further include a firstoptical signal processing module 801, a second optical signal processingmodule 802, and a third optical signal processing module 803.

The first optical signal processing module 801 is connected to atransceiver end of an intra-group CAWG, the second optical signalprocessing module 802 is connected to a transceiver end of aninter-group CAWG, and the third optical signal processing module 803 isconnected to a transceiver end of an inter-plane CAWG.

As mentioned above, the intra-group CAWG may be configured to implementan interconnection between switches having the same plane identifier andgroup identifier but different intra-group identifiers, the inter-groupCAWG may be configured to implement an interconnection between switcheshaving the same plane identifier and intra-group identifier butdifferent group identifiers, and the inter-plane CAWG may be configuredto implement an interconnection between switches having the same groupidentifier and intra-group identifier but different plane identifiers.

Specifically, the first optical signal processing module 801 isconfigured to: perform multiplexing processing on an optical signaloutput from an intra-group interconnection port 811 of the switch, andinput, to an input port of the CAWG through an input optical fiber ofthe intra-group CAWG, an optical signal obtained after the multiplexingprocessing. The first optical signal processing module 801 is furtherconfigured to: perform demultiplexing processing on the optical signaloutput from an output optical fiber of the intra-group CAWG, and input,to the intra-group interconnection port 811 of the switch, an opticalsignal obtained after the demultiplexing processing.

Similarly, the second optical signal processing module 802 may performsimilar processing on an optical signal that is input to the inter-groupCAWG and an optical signal that is output from the inter-group CAWG, andthis is also the same for the third optical signal processing module803. Details are not described herein again.

When an input/output port of the switch 800 is an electrical interfaceor a white optical port, the first optical signal processing module 801,the second optical signal processing module 802, and the third opticalsignal processing module 803 may be further configured to: convert, intoan optical signal, an electrical signal output from the output port ofthe switch, or convert, into an electrical signal, an optical signalinput from the input port. For a specific implementation process, referto related descriptions in the embodiment shown in FIG. 6. Details arenot described herein again. In this embodiment of this disclosure, a DCNformed by a switch with the foregoing structure may be considered as ahuge data exchange device, each switch in a network architecture may beconsidered as an interface board of the data exchange device, and theforegoing interconnection method may be used between interface boards.Therefore, the data exchange device does not have an independentinterface board and control board, and all exchange functions andcontrol functions are distributed in each interface board, namely, theswitch. Traffic may be forwarded by using a traffic forwarding methoddescribed below.

FIG. 9A and FIG. 9B are a schematic flowchart of a traffic transmissionmethod 900 in a DCN by using K=3 as an example according to anembodiment of this disclosure.

As shown in FIG. 9A and FIG. 9B, the method 900 may include thefollowing steps.

S901. A source switch (S₁, S₂, S₃) performs traffic balancing on targettraffic to obtain N pieces of sub-traffic, and the source switch (S₁,S₂, S₃) separately sends N−1 pieces of sub-traffic in the N pieces ofsub-traffic to N−1 intra-group direct connection switches of the sourceswitch.

The source switch (S₁, S₂, S₃) separately forwards the N−1 pieces ofsub-traffic to a switch (S₁, S₂, P) whose plane identifier and groupidentifier are the same as a plane identifier and a group identifier ofthe source switch and whose intra-group identifier is different from anintra-group identifier of the source switch, where P=1, 2, . . . , andN, and P≠S₃.

Herein, a method for performing the traffic balancing by the sourceswitch may be a traffic balancing method. For example, balancing isperformed based on a quantity of data packets, or balancing is performedbased on a quantity of 5-tuple flows of a data packet. This is notlimited in this embodiment of this disclosure.

In this embodiment of this disclosure, the source switch divides targettraffic into the N pieces of sub-traffic for traffic forwarding, andthis can improve port utilization of a device and in addition canimprove a traffic peak value between switches.

The source switch leaves one of the N pieces of sub-traffic to thesource switch and sends the other N−1 pieces of sub-traffic to the N−1intra-group direct connection switches of the source switch, so thateach switch in a group in which the source switch is located obtains onepiece of sub-traffic.

Case 1:

There is only one different subnetwork identifier between threesubnetwork identifiers of a destination switch (D₁, D₂, D₃) and threesubnetwork identifiers of the source switch (S₁, S₂, S₃), for example,S₁=D₁, S₂=D₂, and S₃≠D₃, and a procedure proceeds to S902.

In this embodiment, the source switch and the destination switch are ina same plane and in a same group.

In S902, because the source switch and the destination switch are in asame group, another switch except the destination switch in the group towhich the source switch belongs may send an obtained piece ofsub-traffic to the destination switch.

A switch (S₁, S₂, Q) separately forwards sub-traffic to a destinationswitch (D₁, D₂, D₃), where Q=1, 2, . . . , and N, and Q≠D₃, and theswitch (S₁, S₂, Q) is N−1 switches except the destination switch in thegroup to which the source switch belongs.

For example, if the source switch is (1, 1, 1) and the destinationswitch is (1, 1, N), in S901, the source switch may separately send theN−1 pieces of sub-traffic to the N−1 switches: switches (1, 1, 2) to (1,1, N), so that each of switches (1, 1, 1) to (1, 1, N) obtains one pieceof sub-traffic.

In S902, switches (1, 1, 1) to (1, 1, N−1) forward the obtained piecesof sub-traffic to the destination switch (1, 1, N), so that thedestination switch (1, 1, N) receives the N−1 pieces of sub-traffic plusone piece of sub-traffic that the destination switch (1, 1, N) obtainsin S901, the destination switch obtains the N pieces of sub-traffic, andthen in S910, the destination switch aggregates the N pieces ofsub-traffic to obtain the target traffic.

Case 2:

There are two different subnetwork identifiers between three subnetworkidentifiers of a destination switch (D₁, D₂, D₃) and three subnetworkidentifiers of the source switch (S₁, S₂, S₃), for example, S₁=D₁,S₂≠D₂, and S₃≠D₃, and the procedure proceeds to S903.

In this embodiment, the source switch and the destination switch are ina same plane but in different groups.

In S903, the switch (S₁, S₂, Q) forwards sub-traffic to a switch (S₁,D₂, Q), where Q=1, 2, . . . , and N.

The switch (S₁, S₂, Q) in a group to which the source switch belongssends the obtained piece of sub-traffic to the switch (S₁, D₂, Q) whoseplane identifier is the same as a plane identifier of the source switch,whose group identifier is the same as a group identifier of thedestination switch, and whose intra-group identifier is the same as anintra-group identifier of the switch (S₁, S₂, Q).

In other words, the switch (S₁, S₂, Q) in the group to which the sourceswitch belongs may send the obtained piece of sub-traffic to aninter-group direct connection switch of the switch (S₁, S₂, Q) in a samegroup as the destination switch, namely, the switch (S₁, D₂, Q).

For example, the source switch is (1, 1, 1) and the destination switchis (1, 2, N). In S901, the source switch may separately send the N−1pieces of sub-traffic to the N−1 switches: switches (1, 1, 2) to (1, 1,N), so that each of switches (1, 1, 1) to (1, 1, N) obtains one piece ofsub-traffic. In S903, the switches (1, 1, 1) to (1, 1, N) separatelyforwards the obtained piece of sub-traffic to switches (1, 2, 1) to (1,2, N), so that each switch in the group to which the destination switchbelongs obtains one piece of sub-traffic.

In S904, N−1 switches except the destination switch in a group to whichthe destination switch belongs forward obtained pieces of sub-traffic tothe destination switch.

Switches (1, 2, 1) to (1, 2, N−1) send the obtained pieces ofsub-traffic to the destination switch (1, 2, N), so that the destinationswitch obtains the N pieces of sub-traffic, and then in S910, thedestination switch aggregates the N pieces of sub-traffic to obtain thetarget traffic.

Case 3:

Three subnetwork identifiers of the destination switch (D₁, D₂, D₃) aredifferent from three subnetwork identifiers of the source switch (S₁,S₂, S₃), and the procedure proceeds to S905 or S907. S905, S906, andS909 are denoted as a method 1, and S907, S908, and S909 are denoted asa method 2.

Method 1:

In S905, the switch (S₁, S₂, Q) forwards sub-traffic to a switch (S₁,D₂, Q), where Q=1, 2, . . . , and N.

The switch (S₁, S₂, Q) in a group to which the source switch belongsforwards the obtained piece of sub-traffic to the correspondinglynumbered switch (S₁, D₂, Q) whose plane identifier is the same as theplane identifier of the source switch and whose group identifier is thesame as the group identifier of the destination switch.

In other words, the switch (S₁, S₂, Q) forwards the received piece ofsub-traffic to an inter-group direct connection switch of the switch(S₁, S₂, Q) in a plane in which the source switch is located, namely,the switch (S₁, D₂, Q).

In S906, the switch (S₁, D₂, Q) forwards the sub-traffic to a switch(D₁, D₂, Q), where Q=1, 2, . . . , and N.

The switch (S₁, D₂, Q) sends the received piece of sub-traffic to theswitch (D₁, D₂, Q) whose plane identifier and group identifier are thesame as a plane identifier and the group identifier of the destinationswitch and whose intra-group identifier is the same as an intra-groupidentifier of the switch (S₁, D₂, Q).

In other words, the switch (S₁, D₂, Q) forwards the received piece ofsub-traffic to a planar direct connection switch of the switch (S₁, D₂,Q) in a plane in which the destination switch is located, namely, theswitch (D₁, D₂, Q).

In this case, the switch (D₁, D₂, Q) that obtains the piece ofsub-traffic is a switch in a group to which the destination switchbelongs, and then in S909, N−1 switches except the destination switch inthe group to which the destination switch belongs forward the obtainedpieces of sub-traffic to the destination switch, so that the destinationswitch obtains the N pieces of sub-traffic, and then in S910, thedestination switch aggregates the N pieces of sub-traffic to obtain thetarget traffic.

Method 2:

In S907, the switch (S₁, S₂, Q) forwards sub-traffic to a switch (D₁,S₂, Q), where Q=1, 2, . . . , and N.

The switch (S₁, S₂, Q) in the group to which the source switch belongssends the obtained piece of sub-traffic to the switch (D₁, S₂, Q) whoseplane identifier is the same as the plane identifier of the destinationswitch, whose group identifier is the same as the group identifier ofthe source switch, and whose intra-group identifier is the same as theintra-group identifier of the switch (S₁, S₂, Q).

In other words, the switch (S₁, S₂, Q) forwards the received piece ofsub-traffic to a planar direct connection switch of the switch (S₁, S₂,Q) in the plane in which the destination switch is located, namely, theswitch (D₁, S₂, Q).

In S908, the switch (D₁, S₂, Q) forwards one piece of sub-traffic to aswitch (D₁, D₂, Q), where Q=1, 2, . . . , and N.

The switch (D₁, S₂, Q) forwards the received piece of sub-traffic to aninter-group direct connection switch of the switch (S₁, S₂, Q) in theplane in which the destination switch is located, namely, the switch(D₁, D₂, Q).

In other words, the switch (D₁, S₂, Q) forwards the obtained piece ofsub-traffic to the switch (D₁, D₂, Q) whose plane identifier and groupidentifier are the same as the plane identifier and the group identifierof the destination switch and whose intra-group identifier is the sameas an intra-group identifier of the switch (D₁, S₂, Q).

In this case, the switch that obtains the piece of traffic is a switchin the group to which the destination switch belongs, and then in S909,the switches except the destination switch in the group to which thedestination switch belongs forward the obtained pieces of sub-traffic tothe destination switch, so that the destination switch obtains the Npieces of sub-traffic, and then in S910, the destination switchaggregates the N pieces of sub-traffic to obtain the target traffic.

In general, a difference between the method 1 and the method 2 is thatthe method 1 is to first perform inter-group traffic forwarding onsub-traffic and then perform inter-plane traffic forwarding whereas themethod 2 is to first perform the inter-plane traffic forwarding on thesub-traffic and then perform the inter-group traffic forwarding.

It should be understood that, the case 1 may further include S₁=D₁,S₂≠D₂, and S₃=D₃, and S₁≠D₁, S₂=D₂, and S₃=D₃. The case 2 may furtherinclude S₁≠D₁, S₂≠D₂, and S₃=D₃, and S₁≠D₁, S₂=D₂, and S₃≠D₃. One of thescenarios is merely used as an example in FIG. 9A and FIG. 9B, and inanother scenario, traffic forwarding may be performed in a similarmanner. Details are not described herein again.

It should be noted that when K>3, a traffic transmission method issimilar to the traffic transmission method exemplified in the method900. For example, when there are at least four different subnetworkidentifiers between the source switch and the destination switch, thetarget traffic needs to be forwarded through a few more hops only in themanner described in S905 to S908. Details are not described herein.

The following describes an execution process of S901 to S910 withreference to specific examples shown in FIG. 10 and FIG. 11.

In the examples shown in FIG. 10 and FIG. 11, the source switch is (1,1, 1) and the destination switch is (3, 2, 2), that is, the threesubnetwork identifiers of the source switch are different from the threesubnetwork identifiers of the destination switch. Therefore, a trafficforwarding process may include S901, S905, S906, S909, and S910, orS901, S907, S908, S909, and S910.

FIG. 10 illustrates a specific execution process of S901, S905, S906,S909, and S910.

In FIG. 10, an execution process of S21 corresponds to S901 in themethod 900.

The source switch separately sends, to the switches (1, 1, 2) to (1, 1,N), the N−1 pieces of sub-traffic in the N pieces of sub-trafficobtained after the traffic balancing is performed on the target traffic,so that each of the switches (1, 1, 1) to (1, 1, N) obtains one piece ofsub-traffic.

The switches (1, 1, 2) to (1, 1, N) are intra-group direct connectionswitches that are connected to the source switch (1, 1, 1) through anintra-group interconnection port. Therefore, the source switch (1, 1, 1)may forward the N−1 pieces of sub-traffic to the switches (1, 1, 2) to(1, 1, N) through the intra-group interconnection port.

An execution process of S22 corresponds to S905 in the method 900.

In S22, the switches (1, 1, 1) to (1, 1, N) that obtain pieces ofsub-traffic separately send the obtained pieces of sub-traffic to theswitches (1, 2, 1) to (1, 2, N).

Specifically, the switch (1, 1, 1) forwards the obtained piece ofsub-traffic to the switch (1, 2, 1), the switch (1, 1, 2) forwards theobtained piece of sub-traffic to a switch (1, 2, 2), and so on. In S22,the switches perform the inter-group traffic forwarding, and the Npieces of sub-traffic are forwarded to N switches whose plane identifieris the same as the plane identifier of the source switch and whose groupidentifier is the same as the group identifier of the destinationswitch.

The switch (1, 1, 1) and the switch (1, 2, 1), the switch (1, 1, 2) andthe switch (1, 2, 2), . . . , and the switch (1, 1, N) and the switch(1, 2, N) are switches interconnected through an inter-groupinterconnection port. Therefore, the switches (1, 1, 1) to (1, 1, N) mayforward the obtained pieces of sub-traffic to corresponding switches inthe switches (1, 2, 1) to (1, 2, N) through respective inter-groupinterconnection ports.

An execution process of S23 corresponds to S906 in the method 900.

In S23, the switches (1, 2, 1) to (1, 2, N) separately forward theobtained pieces of sub-traffic to switches (3, 2, 1) to (3, 2, N).

Specifically, the switch (1, 2, 1) forwards the obtained piece ofsub-traffic to the switch (3, 2, 1), the switch (1, 2, 2) forwards theobtained piece of sub-traffic to the switch (3, 2, 2), and so on. InS23, the switches perform the inter-plane traffic forwarding, and the Npieces of sub-traffic are forwarded to a group of switches whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the destination switch.

The switch (1, 2, 1) and the switch (3, 2, 1), the switch (1, 2, 2) andthe switch (3, 2, 2), . . . , and the switch (1, 2, N) and the switch(3, 2, N) are switches interconnected through an inter-planeinterconnection port. Therefore, the switches (1, 2, 1) to (1, 2, N) mayforward the obtained pieces of sub-traffic to corresponding switches inthe switches (3, 2, 1) to (3, 2, N) through respective inter-planeinterconnection ports.

An execution process of S24 corresponds to S909 in the method 900.

In S24, the pieces of sub-traffic obtained by N−1 switches except thedestination switch (3, 2, 2) in the switches (3, 2, 1) to (3, 2, N) areforwarded to the switch (3, 2, 2).

In this way, the destination switch (3, 2, 2) obtains the N pieces ofsub-traffic, and further, the destination switch (3, 2, 2) performsS910, and aggregates the obtained N pieces of sub-traffic to obtain thetarget traffic. At this point, traffic forwarding ends.

Therefore, the traffic transmission method shown in FIG. 10 may besummarized as follows:

First, intra-group balancing is performed on the target traffic. Thesource switch allocates the N pieces of sub-traffic to the N switches inthe group.

Next, the inter-group traffic forwarding is performed. The N switchesthat obtain the pieces of sub-traffic separately forward the obtainedpieces of sub-traffic to a group of switches whose plane identifier isthe same as the plane identifier of the source switch and whose groupidentifier is the same as the group identifier of the destinationswitch.

Then, the inter-plane traffic forwarding is performed. The N switchesthat obtain the pieces of sub-traffic forward the obtained pieces ofsub-traffic to the group of switches whose plane identifier and groupidentifier are the same as the plane identifier and the group identifierof the destination switch.

Finally, intra-group traffic aggregation is performed. The N−1 switchesexcept the destination switch in the group to which the destinationswitch belongs forward the obtained pieces of sub-traffic to thedestination switch, and the destination switch aggregates the obtained Npieces of sub-traffic to obtain the target traffic.

In an example shown in FIGS. 11, S31 and S34 respectively correspond toS21 and S24 in FIG. 10. Details are not described herein.

Different from the traffic transmission method shown in FIG. 10, thetraffic transmission method shown in FIG. 11 is to first perform theinter-plane traffic forwarding and then perform the inter-group trafficforwarding, and a specific execution process is as follows:

An execution process of S32 corresponds to S907 in the method 900.

In S32, the switches (1, 1, 1) to (1, 1, N) that obtain pieces ofsub-traffic separately send the obtained pieces of sub-traffic toswitches (3, 1, 1) to (3, 1, N).

Specifically, the switch (1, 1, 1) forwards the obtained piece ofsub-traffic to the switch (3, 1, 1), the switch (1, 1, 2) forwards theobtained piece of sub-traffic to a switch (3, 1, 2), and so on. In S32,the switches perform the inter-plane traffic forwarding, and the Nswitches that obtain pieces of sub-traffic forward the N pieces ofsub-traffic to a group of switches whose plane identifier is the same asthe plane identifier of the destination switch and whose groupidentifier is the same as the group identifier of the source switch.

The switch (1, 1, 1) and the switch (3, 1, 1), the switch (1, 1, 2) andthe switch (3, 1, 2), . . . , and the switch (1, 1, N) and the switch(3, 1, N) are switches interconnected through an inter-planeinterconnection port. Therefore, the switches (1, 1, 1) to (1, 1, N) mayforward the obtained pieces of sub-traffic to corresponding switches inthe switches (3, 1, 1) to (3, 1, N) through respective inter-planeinterconnection ports.

An execution process of S33 corresponds to S908 in the method 900.

In S33, the switches (3, 1, 1) to (3, 1, N) separately forward theobtained pieces of sub-traffic to switches (3, 2, 1) to (3, 2, N).

Specifically, the switch (3, 1, 1) forwards the obtained piece ofsub-traffic to the switch (3, 2, 1), the switch (3, 1, 2) forwards theobtained piece of sub-traffic to the switch (3, 2, 2), and so on. InS33, the switches perform the inter-group traffic forwarding, and the Npieces of sub-traffic are forwarded to a group of switches whose planeidentifier and group identifier are the same as the plane identifier andthe group identifier of the destination switch.

The switch (3, 1, 1) and the switch (3, 2, 1), the switch (3, 1, 2) andthe switch (3, 2, 2), . . . , and the switch (3, 1, N) and the switch(3, 2, N) are switches interconnected through an inter-groupinterconnection port. Therefore, the switches (3, 1, 1) to (3, 1, N) mayforward the obtained pieces of sub-traffic to corresponding switches inthe switches (3, 2, 1) to (3, 2, N) through respective inter-groupinterconnection ports.

Therefore, the traffic transmission method shown in FIG. 11 may besummarized as follows:

First, intra-group balancing is performed on the target traffic. Thesource switch allocates the N pieces of sub-traffic to the N switches inthe group.

Next, the inter-plane traffic forwarding is performed. The N switchesthat obtain the pieces of sub-traffic separately forward the N pieces ofsub-traffic to the group of switches whose plane identifier is the sameas the plane identifier of the destination switch and whose groupidentifier is the same as the group identifier of the source switch.

Then, the inter-group traffic forwarding is performed. The N switchesthat obtain the pieces of sub-traffic forward the obtained pieces ofsub-traffic to the group of switches whose plane identifier and groupidentifier are the same as the plane identifier and the group identifierof the destination switch.

Finally, intra-group traffic aggregation is performed. The N−1 switchesexcept the destination switch in the group to which the destinationswitch belongs forward the obtained pieces of sub-traffic to thedestination switch, and the destination switch aggregates the obtained Npieces of sub-traffic to obtain the target traffic.

It should be understood that the traffic transmission methods shown inFIG. 9A and FIG. 9B to FIG. 11 are merely examples, and should notconstitute any limitation on this embodiment of this disclosure, andanother traffic forwarding method obtained based on the traffictransmission methods exemplified in this embodiment of this disclosureshould fall within the protection scope of this embodiment of thisdisclosure. For example, in this embodiment of this disclosure, first,inter-plane traffic balancing may alternatively be performed, next, theinter-group traffic forwarding is performed, then, intra-group trafficforwarding is performed, and finally, inter-plane traffic aggregation isperformed. The switch (1, 1, 1) separately sends the N−1 pieces ofsub-traffic to an inter-plane direct connection switch (P, 1, 1), next,a switch (Q, 1, 1) forwards an obtained piece of sub-traffic to aninter-group interconnection switch (Q, 2, 1), then, the switch (Q, 2, 1)forwards the obtained piece of sub-traffic to an intra-groupinterconnection switch (Q, 2, 2), and finally, a switch (W, 2, 2)forwards the obtained piece of sub-traffic to an inter-planeinterconnection switch (3, 2, 2), where P=2, 3, . . . , and N, Q=1, 2, .. . , and N, and W=1, 3, . . . , and N. Alternatively, first,inter-group traffic balancing may be performed, next, the inter-planetraffic forwarding is performed, then, the intra-group trafficforwarding is performed, and finally, inter-group traffic aggregation isperformed. The switch (1, 1, 1) separately sends the N−1 pieces ofsub-traffic to an inter-group direct connection switch (1, P, 1), next,a switch (1, Q, 1) forwards an obtained piece of sub-traffic to aninter-plane interconnection switch (3, Q, 1), then, the switch (3, Q, 1)forwards the obtained piece of sub-traffic to an inter-groupinterconnection switch (3, Q, 2), and finally, a switch (3, W, 2)forwards the obtained piece of sub-traffic to an inter-groupinterconnection switch (3, 2, 2), where P=2, 3, . . . , and N, Q=1, 2, .. . , and N, and W=1, 3, . . . , and N.

The foregoing describes in detail the traffic transmission methodsaccording to the embodiments of this disclosure with reference to FIG.9A and FIG. 9B to FIG. 11. It can be learned from the foregoingdescription that the traffic transmission methods according to theembodiments of this disclosure use unequal-cost multi-path forwarding.To implement forwarding of the target traffic between any two switchesin the DCN, a transmission path between every two switches in the DCNneeds to be pre-determined. The following describes in detail how todetermine the transmission path between the any two switches in the DCNwith reference to FIG. 12 to FIG. 14.

FIG. 12 is a schematic flowchart of a traffic transmission method 1200in a DCN according to another embodiment of this disclosure. The method1200 may be applied to a DCN in the foregoing embodiment, such as theDCN 100 shown in FIG. 1.

As shown in FIG. 12, the method 1200 may include the following content:

S1210. A source switch receives target traffic sent by a server.

S1220. The source switch determines a target transmission path from thesource switch to a destination switch based on a pre-stored transmissionpath set, where the pre-stored transmission path set includes atransmission path between any two switches in the DCN, and thetransmission path between every two switches includes a plurality oftransmission paths.

S1230. The source switch sends the target traffic to the destinationswitch over the target transmission path.

The source switch is any switch in the DCN, and the destination switchis any switch except the source switch in the DCN.

It should be understood that, in this embodiment of this disclosure, theforegoing transmission path set may be pre-stored in each switch, or theforegoing transmission path set may be stored in a shared memory. Whenthe target traffic needs to be forwarded, each switch may obtain thetransmission path set from the shared memory, and query the targettransmission path from the source switch to the destination switch inthe transmission path set, so as to forward the target traffic based onthe target transmission path.

Therefore, in the traffic transmission method in this embodiment of thisdisclosure, the target transmission path from the source switch to thedestination switch is pre-determined. When traffic is forwarded, thetarget traffic may be forwarded only by needing to query the pre-storedtransmission path set, so that a traffic forwarding delay can beshortened.

Optionally, in this embodiment of this disclosure, the method 1200further includes: generating the target transmission path from thesource switch to the destination switch; and adding the targettransmission path to the transmission path set.

The transmission path between the any two switches in the DCN isdetermined, and the transmission path between the two switches is addedto the transmission path set. In this way, when traffic is forwardedbetween the any two switches in the DCN, the transmission path betweenthe two switches may be obtained only by needing to query thetransmission path set.

For example, in the transmission path set, a transmission path from asource switch (1, 1, 1) to a destination switch (3, 2, 2) may include atransmission path in S21, S22, S23, and S24 shown in FIG. 10, and mayspecifically include (1, 1, 1)→(1, 1, P), (1, 1, Q)→(1, 2, Q)→(3, 2, Q),and (3, 2, W)→(3, 2, 2), where P=2, . . . , and N, Q=1, 2, . . . , andN, and W=1, 3, . . . , and N.

Alternatively, in the transmission path set, a transmission path from asource switch (1, 1, 1) to a destination switch (3, 2, 2) may include atransmission path in S31, S32, S33, and S34 shown in FIG. 11, and mayspecifically include (1, 1, 1)→(1, 1, P), (1, 1, Q)→(3, 1, Q)→(3, 2, Q),and (3, 2, W)→(3, 2, 2), where P=2, . . . , and N, Q=1, 2, . . . , andN, and W=1, 3, . . . , and N.

In a specific embodiment, the generating the target transmission pathfrom the source switch to the destination switch may include:determining a first path set, where the first path set includes aone-hop reachable transmission path between switches in the DCN;determining a first switch set and a second switch set, where the firstswitch set includes the source switch and all direct connection switchesof the source switch, and the second switch set includes the destinationswitch and all direct connection switches of the destination switch;determining a second path set from a switch in the first switch set to aswitch in the second switch set based on the first path set; anddetermining the target transmission path from the source switch to thedestination switch based on the first path set and the second path set,where the target transmission path includes a plurality of transmissionpaths from the source switch to the destination switch.

The first path set includes all one-hop reachable paths in an entirenetwork. For example, the DCN includes a first switch, and then thefirst path set may include a one-hop path between the first switch andeach switch in K direct connection switch groups of the first switch.

For example, for a specific example shown in FIG. 10 or FIG. 11, thefirst path set may include N−1 transmission paths between the switch (1,1, 1) and a switch (1, 1, P), N−1 transmission paths between the switch(1, 1, 1) and a switch (1, Q, 1), and N−1 transmission paths between theswitch (1, 1, 1) and a switch (W, 1, 1), where P=2, . . . , and N, Q=2,. . . , and N, and W=2, . . . , and N.

In this embodiment of this disclosure, the first switch set includes thesource switch and all the direct connection switches of the sourceswitch, namely, K direct connection switch groups of the source switch,and the second switch set includes the destination switch and all thedirect connection switches of the destination switch, namely, K directconnection switch groups of the destination switch.

For example, the source switch is (1, 1, 1), the destination switch is(3, 2, 2), the first switch set may include (1, 1, P), (1, Q, 1), and(W, 1, 1), and the second switch set includes (3, 2, P), (3, Q, 2), and(W, 2, 2), where P=1, 2, . . . , and N, Q=1, 2, . . . , and N, and W=1,2, . . . , and N.

The second path set from the switch in the first switch set to theswitch in the second switch set may be determined based on the firstpath set. The second path set includes a transmission path from thesource switch and all the direct connection switches of the sourceswitch to the destination switch and all the direct connection switchesof the destination switch, and the transmission path in the second pathset is one or more hops.

For example, the source switch is (1, 1, 1), the destination switch is(3, 2, 2), the second path set includes a forwarding path in S22 and S23shown in FIG. 10, and may specifically include (1, 1, Q)→(1, 2, Q)→(3,2, Q), or the second path set may include a transmission path in S32 andS33 shown in FIG. 11, and may specifically include (1, 1, Q)→(3, 1,Q)→(3, 2, Q), where Q=1, 2, . . . , and N, or the second path set mayinclude (1, 1, Q)→(1, 3, Q)→(3, 3, Q)→(3, 2, Q), (1, Q, 1)→(1, Q, 2)→(3,Q, 2), or the like.

After the second path set is determined, the target transmission pathfrom the source switch to the destination switch may be furtherdetermined based on the first path set and the second path set.

In a specific embodiment, the determining the target transmission pathfrom the source switch to the destination switch based on the first pathset and the second path set includes: determining a first transmissionpath group in the second path set, where the first transmission pathgroup includes N transmission paths with a minimum hop count from thesource switch and a first direct connection switch group interconnectedwith the source switch to the destination switch and a second directconnection switch group interconnected with the destination switch, thefirst direct connection switch group is any direct connection switchgroup interconnected with the source switch, and the second directconnection switch group is any direct connection switch groupinterconnected with the destination switch; determining, in the firstpath set, a second transmission path group from the source switch to thefirst direct connection switch group, and a third transmission pathgroup from the second direct connection switch group to the destinationswitch, where the second transmission path group includes N−1transmission paths from the source switch to the first direct connectionswitch group, and the third transmission path group includes N−1transmission paths from the second direct connection switch group to thedestination switch; and determining the target transmission path fromthe source switch to the destination switch based on the secondtransmission path group, the first transmission path group, and thethird transmission path group.

Specifically, the second path set may include all reachable transmissionpaths from the switch in the first switch set to the switch in thesecond switch set, A hop count of the transmission path from the switchin the first switch set to the switch in the second switch set may bedifferent in the second path set. Therefore, the N transmission pathswith the minimum hop count from the source switch and the first directconnection switch group interconnected with the source switch to thedestination switch and the second direct connection switch groupinterconnected with the destination switch may be determined in thesecond path set, and the N transmission paths with the minimum hop countare denoted as the first transmission path group. The first directconnection switch group includes N−1 switches directly connected to thesource switch, that is, the first switch set includes N switches. Thesecond direct connection switch group includes N−1 switches directlyconnected to the destination switch, that is, the second switch setincludes N switches. The N transmission paths included in the firsttransmission path group are respectively used to connect the N switchesin the first switch set to the N switches in the second switch set, orin other words, the switch in the first switch set may transmit trafficto a corresponding switch in the second switch set over a correspondingtransmission path.

For example, the first transmission path group includes the forwardingpath in S22 and S23 shown in FIG. 10, The N transmission paths includedin the first transmission path group are (1, 1, Q)→(1, 2, Q)→(3, 2, Q),where Q=1, 2, . . . , and N. A transmission path corresponding to theswitch (1, 1, 1) in the first switch set is (1, 1, 1)→(1, 2, 1)→(3, 2,1). Therefore, the switch (1, 1, 1) may forward traffic to the switch(3, 2, 1) over a transmission path (1, 1, 1)→(1, 2, 1)→(3, 2, 1).Similarly, a transmission path corresponding to a switch (1, 1, N) is(1, 1, 1)→(1, 2, 1)→(3, 2, 1), and the switch (1, 1, N) may forwardtraffic to the switch (3, 2, N) over a transmission path (1, 1, N)→(1,2, N)→(3, 2, N).

After the first transmission path group is determined in the second pathset, a transmission path between a first hop and a last hop from thesource switch to the destination switch is relatively determined.Further, the N−1 transmission paths from the source switch to the N−1switches in the first direct connection switch group of the sourceswitch may be determined (the N−1 transmission paths are denoted as thesecond transmission path group). In other words, the first hop from thesource switch to the destination switch is determined. The N−1transmission paths from the N−1 switches in the second direct connectionswitch group of the destination switch to the destination switch aredetermined (the N−1 transmission paths are denoted as the thirdtransmission path group). In other words, the last hop from the sourceswitch to the destination switch is determined. At this point, the firsthop, the last hop, and the transmission path between the first hop andthe last hop from the source switch to the destination switch aredetermined, and then, the target transmission path from the sourceswitch to the destination switch may be determined based on the firsttransmission path group, the second transmission path group, and thethird transmission path group. Specifically, a combined path of thesecond transmission path group, the first transmission path group, andthe third transmission path group may be used as the target transmissionpath from the source switch to the destination switch.

For example, the source switch is (1, 1, 1), the destination switch is(3, 2, 2), and the first transmission path group may include theforwarding path in S22 and S23 shown in FIG. 10, that is, the Ntransmission paths included in the first transmission path group are (1,1, Q)→(1, 2, Q)→(3, 2, Q), where Q=1, 2, . . . , and N. Then, the N−1transmission paths included in the second transmission path group may be(1, 1, 1)→(1, 1, P), where P=2, . . . , and N. The N−1 transmissionpaths included in the third transmission path group may be (3, 2, W)→(3,2, 2), where W=1, 3, . . . , and N. The first transmission path group,the second transmission path group, and the third transmission pathgroup are combined to obtain the target transmission path: (1, 1, 1)→(1,1, P) (corresponding to S21 in FIG. 10), (1, 1, Q)→(1, 2, Q)→(3, 2, Q)(corresponding to S22 and S23 in FIG. 10), and (3, 2, W)→(3, 2, 2)(corresponding to S24 in FIG. 10), where P=2, . . . , and N, Q=1, 2, . .. , and N, and W=1, 3, . . . , and N, that is, the obtained targettransmission path may be the transmission path shown in S21, S22, S23,and S24 in FIG. 10.

It should be noted that, in this embodiment of this disclosure, thefirst direct connection switch group is N−1 direct connection switchesof the source switch. For example, the first direct connection switchgroup may be an intra-group direct connection switch group, aninter-group direct connection switch group or a planar direct connectionswitch group of the source switch, and in the first hop, the sourceswitch may separately forward N−1 pieces of sub-traffic to the N−1switches of the first direct connection switch group. The second directconnection switch group is N−1 direct connection switches of thedestination switch. For example, the second direct connection switchgroup may be an intra-group direct connection switch group, aninter-group direct connection switch group or a planar direct connectionswitch group of the destination switch. In the last hop, the N−1switches in the second direct connection switch group forward the N−1pieces of sub-traffic to the destination switch.

After the target transmission path from the source switch to thedestination switch is obtained, further, S1230 may include the followingsteps.

S1231. The source switch performs traffic balancing on the targettraffic to obtain N pieces of sub-traffic.

S1232. The source switch separately sends N−1 pieces of sub-traffic inthe N pieces of sub-traffic to N−1 direct connection switches in thefirst direct connection switch group over the N−1 transmission paths inthe second transmission path group.

Optionally, when the DCN is a three-level structure, and the firstdirect connection switch group is an intra-group direct connectionswitch group, an execution process of S1231 and S1232 may correspond toS901 in the method 900 shown in FIG. 9A and FIG. 9B, S21 in the exampleshown in FIG. 10, or S31 in the example shown in FIG. 11.

S1233. The source switch and the first direct connection switch groupseparately send the N pieces of sub-traffic to the destination switchand N−1 direct connection switches in the second direct connectionswitch group over the N transmission paths in the first transmissionpath group.

As described above, a head end of each transmission path in the firsttransmission path is a switch in the first switch set, and a tail end isa switch in the second switch set. The N switches in the first switchset may be connected to the corresponding N switches in the secondswitch set over the N transmission paths in the first transmission pathgroup. In this way, a switch in the first switch set may forward oneobtained piece of sub-traffic to a switch at an end of the transmissionpath over a corresponding transmission path, namely, a switch in thesecond switch set. For example, the first switch set includes a firstswitch, the second switch set includes a second switch, the firsttransmission path group includes a first transmission path, the firsttransmission path is a transmission path from the first switch to thesecond switch, and the first switch may forward the obtained piece ofsub-traffic to the second switch over the first transmission path.

Optionally, when the DCN is the three-level structure, the first directconnection switch group is an intra-group direct connection switch groupof the source switch, and the second direct connection switch group isan intra-group direct connection switch group of the destination switch,an execution process of S1233 may correspond to S905 and S906, or S907and S908 in the method 900 shown in FIG. 9A and FIG. 9B, S22 and S23 inthe example shown in FIG. 10, or S32 and S33 in the example shown inFIG. 11.

S1234. The N−1 switches in the second direct connection switch groupsend the N−1 pieces of sub-traffic to the destination switch over theN−1 transmission paths in the third transmission path group.

Optionally, when the DCN is the three-level structure, the first directconnection switch group is the intra-group direct connection switchgroup of the source switch, and the second direct connection switchgroup is the intra-group direct connection switch group of thedestination switch, an execution process of S1234 may correspond to S909in the method 900 shown in FIG. 9A and FIG. 9B, S24 in the example shownin FIG. 10, or S34 in the example shown in FIG. 11. Details are notdescribed herein again.

S1235. The destination switch aggregates the received N pieces ofsub-traffic to obtain the target traffic.

An execution process of S1235 may correspond to S910 in the method 900shown in FIG. 9A and FIG. 9B. Details are not described herein again.

The following describes an execution process of S1233 with reference toFIG. 13 and FIG. 14 by using an example in which K=3, that is, the DCNis a three-level structure.

In a specific implementation, as shown in FIG. 13, S1233 may include thefollowing steps.

S41. A first switch sends, over a first transmission sub-path in thefirst transmission path group, an obtained piece of sub-traffic to asecond switch whose plane identifier is the same as a plane identifierof the source switch, whose group identifier is the same as a groupidentifier of the destination switch, and whose intra-group identifieris the same as an intra-group identifier of the first switch, where thefirst switch is the source switch or any switch in the first directconnection switch group, and the first transmission sub-path is atransmission path from the first switch to the second switch.

Specifically, an execution process of S41 may correspond to S905 in themethod 900 shown in FIG. 9A and FIG. 9B, or S22 in the specific exampleshown in FIG. 10. For a detailed execution process, refer to relateddescriptions in the foregoing embodiment. Details are not describedherein again.

In this embodiment, the first transmission path group includestransmission paths in S22 and S23, and the first transmission sub-pathis a transmission path in S22. For example, the first switch is (1, 1,P), the second switch is (1, 2, P), and the first transmission sub-pathis (1, 1, P)→(1, 2, P), where P=1, 2, . . . , and N.

S42. The second switch sends, over a second transmission sub-path in thefirst transmission path group, the received piece of sub-traffic to athird switch whose plane identifier and group identifier are the same asa plane identifier and the group identifier of the destination switchand whose intra-group identifier is the same as the intra-groupidentifier of the second switch, where the third switch is thedestination switch or any switch in the second direct connection switchgroup, and the second transmission sub-path is a transmission path fromthe second switch to the third switch.

Specifically, an execution process of S42 may correspond to S906 in themethod 900 shown in FIG. 9A and FIG. 9B, or S23 in the specific exampleshown in FIG. 10. For a detailed execution process, refer to relateddescriptions in the foregoing embodiment. Details are not describedherein again.

In this embodiment, the first transmission path group includes thetransmission paths in S22 and S23, and the second transmission sub-pathis a transmission path in S23. For example, the second switch is (1, 2,P), the third switch is (3, 2, P), and the second transmission sub-pathis (1, 2, P)→(3, 2, P), where P=1, 2, . . . , and N.

In another specific implementation, as shown in FIG. 14, S1233 mayinclude the following steps.

S51. A first switch sends, over a first transmission sub-path in thefirst transmission path group, an obtained piece of sub-traffic to asecond switch whose plane identifier is the same as a plane identifierof the destination switch, whose group identifier is the same as a groupidentifier of the source switch, and whose intra-group identifier is thesame as an intra-group identifier of the first switch, where the firstswitch is the source switch or any switch in the first direct connectionswitch group, and the first transmission sub-path is a transmission pathfrom the first switch to the second switch.

Specifically, an execution process of S51 may correspond to S907 in themethod 900 shown in FIG. 9A and FIG. 9B, or S32 in the specific exampleshown in FIG. 11. For a detailed execution process, refer to relateddescriptions in the foregoing embodiment. Details are not describedherein again. In this embodiment, the first transmission path groupincludes transmission paths in S32 and S33, and the first transmissionsub-path is a transmission path in S32. For example, the first switch is(1, 1, P), the second switch is (3, 1, P), and the first transmissionsub-path is (1, 1, P)→(3, 1, P), where P=1, 2, . . . , and N.

S52. The second switch sends, over a second transmission sub-path in thefirst transmission path group, the received piece of sub-traffic to athird switch whose plane identifier and group identifier are the same asthe plane identifier and a group identifier of the destination switchand whose intra-group identifier is the same as the intra-groupidentifier of the second switch, where the third switch is thedestination switch or any switch in the second direct connection switchgroup, and the second transmission sub-path is a transmission path fromthe second switch to the third switch.

Specifically, an execution process of S52 may correspond to S908 in themethod 900 shown in FIG. 9A and FIG. 9B, or S33 in the specific exampleshown in FIG. 11. For a detailed execution process, refer to relateddescriptions in the foregoing embodiment. Details are not describedherein again. In this embodiment, the first transmission path groupincludes the transmission paths in S32 and S33, and the secondtransmission sub-path is a transmission path in S33. For example, thesecond switch is (3, 1, P), the third switch is (3, 2, P), and thesecond transmission sub-path is (3, 1, P)→(3, 2, P), where P=1, 2, . . ., and N. Therefore, according to the traffic transmission method in theDCN in this embodiment of this disclosure, a maximum of four hops may berequired from the source switch to the destination switch. However, whena conventional Clos structure is used, five layers of network devicesneed to be established in a case of a same switching capacity, andcorresponding traffic forwarding requires eight hops. Therefore, thetraffic transmission method in this embodiment of this disclosure canreduce routing complexity and in addition help reduce a transmissiondelay.

An embodiment of this disclosure further provides a computer-readablestorage medium. The computer-readable storage medium stores one or moreprograms, and the one or more programs include an instruction. Whenexecuted by a portable electronic device that includes a plurality ofdisclosure programs, the instruction enables the portable electronicdevice to perform the method in the embodiments shown in FIG. 9A andFIG. 9B to FIG. 14.

An embodiment of this disclosure further provides a computer programproduct. The computer program product includes an instruction. Whenexecuted by a computer, the computer program enables the computer toexecute the corresponding procedures of the method in the embodimentsshown in FIG. 9A and FIG. 9B to FIG. 14.

It should be understood that specific examples in this disclosure aremerely intended to help a person skilled in the art better understandthe embodiments of this disclosure, but not to limit the scope of theembodiments of this disclosure.

It should be further understood that sequence numbers of the foregoingprocesses do not mean execution sequences in various embodiments of thisdisclosure. The execution sequences of the processes should bedetermined according to functions and internal logic of the processes,and should not be construed as any limitation on the implementationprocesses of the embodiments of this disclosure.

A person of ordinary skill in the art may be aware that, in combinationwith the examples described in the embodiments disclosed in thisspecification, units and algorithm steps may be implemented byelectronic hardware, computer software, or a combination thereof. Toclearly describe the interchangeability between the hardware and thesoftware, the foregoing has generally described compositions and stepsof each example according to functions. Whether the functions areperformed by hardware or software depends on particular disclosures anddesign constraint conditions of the technical solutions. A personskilled in the art may use different methods to implement the describedfunctions for each particular disclosure, but it should not beconsidered that the implementation goes beyond the scope of thisdisclosure.

It may be clearly understood by a person skilled in the art that, forthe purpose of convenient and brief description, for a specific processof the method described above, refer to a corresponding description inthe foregoing apparatus embodiments. Details are not described herein.

In the several embodiments provided in this disclosure, it should beunderstood that the disclosed system, apparatus, and method may beimplemented in other manners. For example, the described apparatusembodiment is merely an example. For example, the unit division ismerely logical function division and may be other division in actualimplementation. For example, a plurality of units or components may becombined or integrated into another system, or some features may beignored or not performed. In addition, the displayed or discussed mutualcouplings or direct couplings or communication connections may beimplemented through some interfaces, indirect couplings or communicationconnections between the apparatuses or units, or electrical connections,mechanical connections, or connections in other forms.

The units described as separate parts may or may not be physicallyseparate, and parts displayed as units may or may not be physical units,may be located in one position, or may be distributed on a plurality ofnetwork units. Some or all of the units may be selected according toactual requirements to achieve the objectives of the solutions of theembodiments in this disclosure.

In addition, functional units in the embodiments of this disclosure maybe integrated into one processing unit, or each of the units may existalone physically, or two or more units are integrated into one unit. Theintegrated unit may be implemented in a form of hardware, or may beimplemented in a form of a software functional unit.

When the integrated unit is implemented in the form of a softwarefunctional unit and sold or used as an independent product, theintegrated unit may be stored in a computer-readable storage medium.Based on such an understanding, the technical solutions of thisdisclosure may be implemented in the form of a software product. Thecomputer software product is stored in a storage medium and includesseveral instructions for instructing a computer device (which may be apersonal computer, a server, or a network device) to perform all or someof the steps of the methods described in the embodiments of thisdisclosure. The foregoing storage medium includes: any medium that canstore program code, such as a USB flash drive, a removable hard disk, aread-only memory (ROM), a random-access memory (RAM), a magnetic disk,or an optical disc.

The foregoing descriptions are merely specific embodiments of thisdisclosure, but are not intended to limit the protection scope of thisdisclosure. Any modification or replacement readily figured out by aperson skilled in the art within the technical scope disclosed in thisdisclosure shall fall within the protection scope of this disclosure.Therefore, the protection scope of this disclosure shall be subject tothe protection scope of the claims.

What is claimed is:
 1. A data center network (DCN) comprising: Nfirst-level subnetworks, wherein each first-level subnetwork comprises Nsecond-level subnetworks, wherein each k^(th)-level subnetwork comprisesN (k+1)^(th)-level subnetworks, wherein each (K−1)^(th)-level subnetworkcomprises switches, wherein N, K, and k are integers, wherein N≥2, K≥2,1<k<K, wherein the DCN is a K-level network, wherein the switchescomprise a first switch, wherein the first switch comprises K subnetworkidentifiers, wherein each of the K subnetwork identifiers indicates alevel of subnetwork to which the first switch belongs and a number ofthe first switch in a (K−1)^(th)-level subnetwork to which the switchbelongs, wherein the first switch is interconnected with each of theremaining switches in K direct connection switch groups, wherein each Kdirect connection switch group comprises N−1 switches of the switches,wherein an i^(th)-level subnetwork identifier of the N−1 switchescomprised in an i^(th) direct connection switch group of the K directconnection switch groups is different from an i^(th)-level subnetworkidentifier of the first switch and is the same as other K−1 subnetworkidentifiers of the first switch, and wherein i=1, . . . , and K.
 2. TheDCN of claim 1, wherein the first switch comprises K interconnectionport groups, wherein each of the K interconnection port groups comprisesN−1 interconnection ports, wherein the K interconnection port groupscorrespond to the K direct connection switch groups, and wherein the N−1interconnection ports in each of the K interconnection port group isconfigured to connect N−1 switches in a corresponding direct connectionswitch group.
 3. The DCN of claim 2, wherein K is 3, wherein the Nfirst-level subnetworks are planes, wherein the N second-levelsubnetworks are groups, wherein identifiers of the N first-levelsubnetworks are plane identifiers, wherein identifiers of the Nsecond-level subnetworks are group identifiers, wherein identifiers ofthird-level subnetworks are intra-group identifiers, wherein a firstdirect connection switch group in the K direct connection switch groupsis a planar direct connection switch group and comprises N−1 switcheswhose plane identifier is different from a plane identifier of the firstswitch, whose group identifier is the same as a group identifier of thefirst switch, and whose intra-group identifier is the same as anintra-group identifier of the first switch, wherein a second directconnection switch group is an inter-group direct connection switch groupand comprises N−1 switches whose group identifier is different from thegroup identifier of the first switch, whose plane identifier is the sameas the plane identifier of the first switch, and whose intra-groupidentifier is the same as the intra-group identifier of the firstswitch, wherein a third direct connection switch group is an intra-groupdirect connection switch group and comprises N−1 switches whoseintra-group identifier is different from the intra-group identifier ofthe first switch, whose plane identifier is the same as the planeidentifier of the first switch, and whose group identifier is the sameas the group identifier of the first switch.
 4. The DCN of claim 3,wherein the K interconnection port groups comprise an inter-planeinterconnection port group, an inter-group interconnection port group,and an intra-group interconnection port group, wherein the inter-planeinterconnection port group comprises N−1 inter-plane interconnectionports, wherein the inter-group interconnection port group comprises N−1inter-group interconnection ports, wherein the intra-groupinterconnection port group comprises N−1 intra-group interconnectionport, wherein the N−1 inter-plane interconnection ports are configuredto connect the N−1 switches in the planar direct connection switchgroup, wherein the N−1 inter-group interconnection ports are configuredto connect the N−1 switches in the inter-group direct connection switchgroup, and wherein the N−1 intra-group interconnection ports areconfigured to connect the N−1 switches in the intra-group directconnection switch group.
 5. The DCN of claim 2, wherein the Kinterconnection port groups of the first switch are connected to the Kdirect connection switch groups through K cyclic arrayed waveguidegratings (CAWGs), wherein each of the K CAWGs comprises N input opticalfibers and N output optical fibers, wherein the N−1 interconnectionports in each interconnection port group of the first switch compriseN−1 input ports and N−1 output ports, wherein the N−1 output ports ineach interconnection port group of the first switch are connected to aninput optical fiber of a first CAWG in the K CAWGs, and wherein the N−1input ports in the interconnection port group are connected to an outputoptical fiber of the first CAWG.
 6. A traffic transmission methodimplemented by a source switch in a data center network (DCN), thetraffic transmission method comprising: receiving target traffic from aserver; determining a target transmission path from the source switch toa destination switch based on a pre-stored transmission path set,wherein the pre-stored transmission path set comprises a transmissionpath between every two switches in the DCN, and wherein eachtransmission path comprises a plurality of sub-transmission paths;sending the target traffic to the destination switch over the targettransmission path; determining a first path set, wherein the first pathset comprises a one-hop reachable transmission path between switches inthe DCN; determining a first switch set and a second switch set, whereinthe first switch set comprises the source switch and all directconnection switches of the source switch, and wherein the second switchset comprises the destination switch and all direct connection switchesof the destination switch; determining a second path set from a switchin the first switch set to a switch in the second switch set based onthe first path set; and further determining the target transmission pathbased on the first path set and the second path set, wherein the targettransmission path comprises a plurality of sub-transmission paths fromthe source switch to the destination switch.
 7. The traffic transmissionmethod of claim 6, further comprising: generating the targettransmission path; and adding the target transmission path to thetransmission path set.
 8. The traffic transmission method of claim 6,further comprising determining a first transmission path group in thesecond path set, wherein the first transmission path group comprises Nsub-transmission paths with a minimum hop count from the source switchand a first direct connection switch group interconnected with thesource switch to the destination switch and a second direct connectionswitch group interconnected with the destination switch, wherein thefirst direct connection switch group is interconnected with the sourceswitch, and wherein the second direct connection switch group isinterconnected with the destination switch.
 9. The traffic transmissionmethod of claim 8, further comprising determining, from the first pathset, a second transmission path group from the source switch to thefirst direct connection switch group and a third transmission path groupfrom the second direct connection switch group to the destinationswitch, wherein the second transmission path group comprises N−1sub-transmission paths from the source switch to the first directconnection switch group, and wherein the third transmission path groupcomprises N−1 sub-transmission paths from the second direct connectionswitch group to the destination switch.
 10. The traffic transmissionmethod of claim 9, further determining the target transmission pathfurther based on the second transmission path group, the firsttransmission path group, and the third transmission path group.
 11. Thetraffic transmission method of claim 10, further comprising performingtraffic balancing on the target traffic to obtain N pieces ofsub-traffic.
 12. The traffic transmission method of claim 11, separatelysending N−1 pieces of sub-traffic in the N pieces of sub-traffic to N−1direct connection switches in the first direct connection switch groupover the N−1 sub-transmission paths in the second transmission pathgroup.
 13. The traffic transmission method of claim 12, furthercomprising separately sending the N pieces of sub-traffic to thedestination switch and N−1 direct connection switches in the seconddirect connection switch group over the N sub-transmission paths in thefirst transmission path group.
 14. A source switch in a data centernetwork (DCN), the source switch comprising: K direct connection switchgroups; K interconnection port groups configured to respectively connectthe K direct connection switch groups; an access port configured toconnect to a server; and a switching chip configured to: receive, fromthe server and through the access port, target traffic, determine atarget transmission path from the source switch to a destination switchbased on a pre-stored transmission path set, wherein the pre-storedtransmission path set comprises a transmission path between every twoswitches in the DCN, and wherein each transmission path comprises aplurality of sub-transmission paths, send the target traffic to thedestination switch over the target transmission path, determine a firstpath set, wherein the first path set comprises a one-hop reachabletransmission path between switches in the DCN; determine a first switchset and a second switch set, wherein the first switch set comprises thesource switch and all direct connection switches of the source switch,and wherein the second switch set comprises the destination switch andall direct connection switches of the destination switch; determine asecond path set from a switch in the first switch set to a switch in thesecond switch set based on the first path set; and further determine thetarget transmission path based on the first path set and the second pathset, wherein the target transmission path comprises a plurality ofsub-transmission paths from the switch to the destination switch. 15.The source switch of claim 14, wherein the source switch furthercomprises a processor configured to: generate the target transmissionpath; and add the target transmission path to the transmission path set.16. The source switch of claim 14, wherein the source switch furthercomprises a processor configured to: determine a first transmission pathgroup in the second path set, wherein the first transmission path groupcomprises N sub-transmission paths with a minimum hop count from thesource switch and a first direct connection switch group interconnectedwith the source switch to the destination switch and a second directconnection switch group interconnected with the destination switch,wherein the first direct connection switch group is interconnected withthe source switch, and wherein the second direct connection switch groupis interconnected with the destination switch; determine, from the firstpath set, a second transmission path group from the source switch to thefirst direct connection switch group and a third transmission path groupfrom the second direct connection switch group to the destinationswitch, wherein the second transmission path group comprises N−1sub-transmission paths from the source switch to the first directconnection switch group, and wherein the third transmission path groupcomprises N−1 transmission paths from the second direct connectionswitch group to the destination switch; and determine the targettransmission path further based on the second transmission path group,the first transmission path group, and the third transmission pathgroup.
 17. The source switch of claim 16, wherein the switching chip isfurther configured to: perform traffic balancing on the target trafficto obtain N pieces of sub-traffic; and separately send N−1 pieces ofsub-traffic in the N pieces of sub-traffic to N−1 direct connectionswitches in the first direct connection switch group over the N−1transmission paths in the second transmission path group.
 18. The sourceswitch of claim 17, wherein K is 3, wherein a first-level subnetwork ofthe DCN is a plane, wherein a second-level subnetwork is a group,wherein an identifier of the first-level subnetwork is a planeidentifier, wherein an identifier of the second-level subnetwork is agroup identifier, wherein an identifier of a third-level subnetwork isan intra-group identifier, and wherein a first direct connection switchgroup in the K direct connection switch groups is a planar directconnection switch group and comprises N−1 switches whose planeidentifier is different from a plane identifier of the source switch,whose group identifier is the same as a group identifier of the sourceswitch, and whose intra-group identifier is the same as an intra-groupidentifier of the source switch.
 19. The source switch of claim 18,wherein a second direct connection switch group is an inter-group directconnection switch group and comprises N−1 switches whose groupidentifier is different from the group identifier of the source switch,whose plane identifier is the same as the plane identifier of the sourceswitch, and whose intra-group identifier is the same as the intra-groupidentifier of the source switch.
 20. The source switch of claim 19,wherein a third direct connection switch group is an intra-group directconnection switch group and comprises N−1 switches whose intra-groupidentifier is different from the intra-group identifier of the sourceswitch, whose plane identifier is the same as the plane identifier ofthe source switch, and whose group identifier is the same as the groupidentifier of the source switch.